Skip to content

Commit

Permalink
Merge pull request #240 from EducationalTestingService/update-stats-m…
Browse files Browse the repository at this point in the history
…odels-and-seaborn

Update versions for `statsmodels` and `seaborn`
  • Loading branch information
jbiggsets committed Sep 25, 2018
2 parents af57970 + b2509da commit af32ade
Show file tree
Hide file tree
Showing 7 changed files with 24 additions and 23 deletions.
4 changes: 2 additions & 2 deletions conda_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ numpy=1.13.3
pandas=0.22.0
scikit-learn=0.19.1
scipy=1.0.0
seaborn=0.8.1
seaborn=0.9.0
skll=1.5.2
statsmodels=0.8.0
statsmodels=0.9.0
sphinx
sphinx_rtd_theme
zeromq
Expand Down
4 changes: 2 additions & 2 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ dependencies:
- pandas=0.22.0
- scikit-learn=0.19.1
- scipy=1.0.0
- seaborn=0.8.1
- seaborn=0.9.0
- skll=1.5.2
- statsmodels=0.8.0
- statsmodels=0.9.0
- parameterized
- zeromq
- sphinx
Expand Down
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ numpy==1.13.3
pandas==0.22.0
scikit-learn==0.19.1
scipy==1.0.0
seaborn==0.8.1
seaborn==0.9.0
skll==1.5.2
statsmodels==0.8.0
statsmodels==0.9.0
openpyxl
xlrd
xlwt
Expand Down
7 changes: 4 additions & 3 deletions rsmtool/notebooks/dff_by_group.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,10 @@
" group_values = sorted(df_melted[group].unique())\n",
" colors = sns.color_palette(\"Greys\", len(group_values))\n",
" with sns.axes_style('whitegrid'), sns.plotting_context('notebook', font_scale=1.2):\n",
" p = sns.factorplot(x='sc1', y='value', hue=group, hue_order = group_values,\n",
" col='feature', col_wrap=3, size=3, scale=0.6, palette=colors,\n",
" sharey=False, sharex=False, legend=False, data=df_melted)\n",
" p = sns.catplot(x='sc1', y='value', hue=group, hue_order = group_values,\n",
" col='feature', col_wrap=3, height=3, scale=0.6, palette=colors,\n",
" sharey=False, sharex=False, legend=False, kind=\"point\",\n",
" data=df_melted)\n",
"\n",
" for i, axis in enumerate(p.axes):\n",
" axis.set_xlabel('score')\n",
Expand Down
8 changes: 4 additions & 4 deletions rsmtool/notebooks/evaluation.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -181,9 +181,9 @@
"\n",
" # make a barplot without a legend since we will \n",
" # add one manually later\n",
" p = sns.factorplot(\"score\", \"value\", \"variable\", kind=\"bar\",\n",
" palette=colors, data=df_scoredist_melted, \n",
" size=3, aspect=2, legend=False)\n",
" p = sns.catplot(\"score\", \"value\", \"variable\", kind=\"bar\",\n",
" palette=colors, data=df_scoredist_melted, \n",
" height=3, aspect=2, legend=False)\n",
" p.set_axis_labels('score', '% of responses')\n",
" \n",
" # add a legend with the right colors\n",
Expand Down Expand Up @@ -233,7 +233,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.4"
"version": "3.6.3"
}
},
"nbformat": 4,
Expand Down
6 changes: 3 additions & 3 deletions rsmtool/notebooks/feature_descriptives.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,9 @@
"with sns.axes_style('whitegrid'):\n",
" # create a barplot without a legend since we will manually\n",
" # add one later\n",
" p = sns.factorplot(\"feature\", \"value\", \"variable\", kind=\"bar\", \n",
" palette=colors, data=df_outliers, size=3, \n",
" aspect=aspect, legend=False)\n",
" p = sns.catplot(\"feature\", \"value\", \"variable\", kind=\"bar\", \n",
" palette=colors, data=df_outliers, height=3, \n",
" aspect=aspect, legend=False)\n",
" p.set_axis_labels('', '% cases truncated to mean +/- 4*sd')\n",
" p.set_xticklabels(rotation=90)\n",
" p.set(ylim=limits)\n",
Expand Down
14 changes: 7 additions & 7 deletions rsmtool/notebooks/preprocessed_features.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
" warnings.filterwarnings('ignore', category=np.VisibleDeprecationWarning)\n",
" with sns.axes_style('white'):\n",
" g = sns.FacetGrid(col='variable', data=df_train_preproc_melted, col_wrap=3, \n",
" col_order=column_order, sharex=False, sharey=False, size=2, \n",
" col_order=column_order, sharex=False, sharey=False, height=2, \n",
" aspect=1)\n",
" g.map(sns.distplot, \"value\", color=\"grey\", kde=False)\n",
" for ax, cname in zip(g.axes, g.col_names):\n",
Expand Down Expand Up @@ -181,9 +181,9 @@
"\n",
" # generate a bar plot but without the legend since we will\n",
" # manually add one later\n",
" p = sns.factorplot(\"feature\", \"value\", \"variable\", kind=\"bar\",\n",
" palette=colors, data=df_mpcor, size=3, \n",
" aspect=aspect, legend=False)\n",
" p = sns.catplot(\"feature\", \"value\", \"variable\", kind=\"bar\",\n",
" palette=colors, data=df_mpcor, height=3, \n",
" aspect=aspect, legend=False)\n",
" p.set_axis_labels('', 'Correlation with score')\n",
" p.set_xticklabels(rotation=90)\n",
" p.set(ylim=limits)\n",
Expand Down Expand Up @@ -252,9 +252,9 @@
" \n",
" # create a barplot but without the legend since\n",
" # we will manually add one later\n",
" p = sns.factorplot(\"feature\", \"value\", \"variable\", kind=\"bar\",\n",
" palette=colors, data=df_mpcor, size=3, \n",
" aspect=aspect, legend=False)\n",
" p = sns.catplot(\"feature\", \"value\", \"variable\", kind=\"bar\",\n",
" palette=colors, data=df_mpcor, height=3, \n",
" aspect=aspect, legend=False)\n",
" p.set_axis_labels('', 'Correlation with length')\n",
" p.set_xticklabels(rotation=90)\n",
" p.set(ylim=limits)\n",
Expand Down

0 comments on commit af32ade

Please sign in to comment.