Commit 940ca1f3 authored by Danniene Wete's avatar Danniene Wete

plot box whisker plots of random seed optimization

parent ced3d742
......@@ -462,9 +462,10 @@
" stopwords_score_train['Accuracy'], color='b', marker='*', ls='--', linewidth=2, label='Train data')\n",
"plt.plot(stopwords_score_test['Percentage of removed stopwords'],\n",
" stopwords_score_test['Accuracy'], color='r', marker='*', ls='--', linewidth=2, label='Test data')\n",
"plt.xlabel('Percentage of removed stopwords')\n",
"plt.ylabel('Accuracy')\n",
"plt.xlabel('Percentage of removed stopwords', fontweight='bold')\n",
"plt.ylabel('Accuracy', fontweight='bold')\n",
"plt.legend()\n",
"plt.savefig('plots_m2c/stopword_removalm2c.png')\n",
"plt.show()"
]
},
......@@ -499,7 +500,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.8"
"version": "3.7.4"
}
},
"nbformat": 4,
......
......@@ -2,9 +2,9 @@
\toprule
{} & Precision & Recall \\
\midrule
WALKING & 0.951 & 0.940 \\
WALKING & 0.949 & 0.942 \\
WALKING\_UPSTAIRS & 0.960 & 0.975 \\
WALKING\_DOWNSTAIRS & 0.931 & 0.936 \\
WALKING\_DOWNSTAIRS & 0.936 & 0.936 \\
SITTING & 0.798 & 0.807 \\
STANDING & 0.827 & 0.806 \\
LAYING & 0.991 & 1.000 \\
......
......@@ -3,8 +3,8 @@
{} & Precision & Recall \\
\midrule
WALKING & 0.997 & 0.941 \\
WALKING\_UPSTAIRS & 0.938 & 0.995 \\
WALKING\_DOWNSTAIRS & 0.989 & 0.993 \\
WALKING\_UPSTAIRS & 0.938 & 0.993 \\
WALKING\_DOWNSTAIRS & 0.987 & 0.993 \\
SITTING & 0.852 & 0.852 \\
STANDING & 0.897 & 0.860 \\
LAYING & 0.963 & 1.000 \\
......
......@@ -2,8 +2,8 @@
\toprule
{} & Top0 & Top1 & Top2 & Top3 & Top4 & Top5 \\
\midrule
Class0 & 466 & 25 & 0 & 4 & 0 & 1 \\
Class1 & 8 & 4 & 0 & 459 & 0 & 0 \\
Class0 & 467 & 24 & 0 & 4 & 0 & 1 \\
Class1 & 9 & 3 & 0 & 459 & 0 & 0 \\
Class2 & 16 & 393 & 0 & 11 & 0 & 0 \\
Class3 & 0 & 0 & 396 & 1 & 5 & 89 \\
Class4 & 0 & 0 & 100 & 3 & 0 & 429 \\
......
......@@ -3,7 +3,7 @@
{} & Top0 & Top1 & Top2 & Top3 & Top4 & Top5 \\
\midrule
Class0 & 1154 & 7 & 0 & 65 & 0 & 0 \\
Class1 & 1 & 4 & 0 & 1068 & 0 & 0 \\
Class1 & 1 & 6 & 0 & 1066 & 0 & 0 \\
Class2 & 3 & 979 & 0 & 4 & 0 & 0 \\
Class3 & 0 & 0 & 1096 & 0 & 54 & 136 \\
Class4 & 0 & 0 & 191 & 1 & 0 & 1182 \\
......
0.0 0.9097387173396675 2386 0.0
0.2222222222222222 0.9097387173396675 2386 0.0
0.4444444444444444 0.9097387173396675 2386 0.0
0.6666666666666666 0.8920936545639634 2386 0.0012573344509639564
0.8888888888888888 0.8893790295215473 2386 0.0020955574182732607
1.1111111111111112 0.8008143875127248 2386 0.005029337803855826
1.3333333333333333 0.6929080420766881 2386 0.013411567476948869
1.5555555555555554 0.5656599932134374 2386 0.04107292539815591
1.7777777777777777 0.5256192738378012 2386 0.11357921207041073
2.0 0.49949100780454697 2386 0.24937133277451803
0.0 0.9363438520130577 2690 0.0
0.2222222222222222 0.9363438520130577 2690 0.0
0.4444444444444444 0.9363438520130577 2690 0.0
0.6666666666666666 0.7822361262241567 2690 0.0011152416356877324
0.8888888888888888 0.7822361262241567 2690 0.0011152416356877324
1.1111111111111112 0.6735582154515778 2690 0.0026022304832713753
1.3333333333333333 0.514145810663765 2690 0.013382899628252789
1.5555555555555554 0.3820729053318825 2690 0.02899628252788104
1.7777777777777777 0.35024483133841133 2690 0.08587360594795539
2.0 0.35038084874863984 2690 0.21078066914498142
This diff is collapsed.
......@@ -2,11 +2,11 @@
\toprule
{} & Precision & Recall \\
\midrule
WALKING & 0.086 & 0.286 \\
WALKING\_UPSTAIRS & 0.108 & 0.274 \\
WALKING\_DOWNSTAIRS & 0.030 & 0.090 \\
SITTING & 0.057 & 0.114 \\
STANDING & 0.085 & 0.147 \\
LAYING & 0.051 & 0.127 \\
WALKING & 0.650 & 0.874 \\
WALKING\_UPSTAIRS & 0.272 & 0.304 \\
WALKING\_DOWNSTAIRS & 0.695 & 0.902 \\
SITTING & 0.663 & 0.505 \\
STANDING & 0.639 & 0.429 \\
LAYING & 0.786 & 0.739 \\
\bottomrule
\end{tabular}
......@@ -214,7 +214,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.8"
"version": "3.7.4"
}
},
"nbformat": 4,
......
......@@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"execution_count": 11,
"metadata": {},
"outputs": [],
"source": [
......@@ -13,7 +13,7 @@
},
{
"cell_type": "code",
"execution_count": 2,
"execution_count": 12,
"metadata": {},
"outputs": [],
"source": [
......@@ -22,7 +22,7 @@
},
{
"cell_type": "code",
"execution_count": 3,
"execution_count": 13,
"metadata": {},
"outputs": [],
"source": [
......@@ -31,7 +31,7 @@
},
{
"cell_type": "code",
"execution_count": 4,
"execution_count": 14,
"metadata": {},
"outputs": [
{
......@@ -128,7 +128,7 @@
"9 9.0 0.440288"
]
},
"execution_count": 4,
"execution_count": 14,
"metadata": {},
"output_type": "execute_result"
}
......@@ -139,7 +139,7 @@
},
{
"cell_type": "code",
"execution_count": 5,
"execution_count": 15,
"metadata": {},
"outputs": [
{
......@@ -156,7 +156,7 @@
},
{
"cell_type": "code",
"execution_count": 6,
"execution_count": 16,
"metadata": {},
"outputs": [],
"source": [
......@@ -167,7 +167,7 @@
},
{
"cell_type": "code",
"execution_count": 7,
"execution_count": 17,
"metadata": {},
"outputs": [
{
......@@ -310,7 +310,7 @@
"14 3.000000 0.504625 0.060009"
]
},
"execution_count": 7,
"execution_count": 17,
"metadata": {},
"output_type": "execute_result"
}
......@@ -322,7 +322,7 @@
},
{
"cell_type": "code",
"execution_count": 8,
"execution_count": 18,
"metadata": {},
"outputs": [],
"source": [
......@@ -333,7 +333,7 @@
},
{
"cell_type": "code",
"execution_count": 9,
"execution_count": 19,
"metadata": {},
"outputs": [
{
......@@ -476,7 +476,7 @@
"14 3.000000 0.424499 0.191467"
]
},
"execution_count": 9,
"execution_count": 19,
"metadata": {},
"output_type": "execute_result"
}
......@@ -488,7 +488,7 @@
},
{
"cell_type": "code",
"execution_count": 10,
"execution_count": 20,
"metadata": {},
"outputs": [
{
......@@ -512,8 +512,8 @@
" stopwords_score_test['Accuracy'], color='r', marker='*', ls='--', linewidth=2, label='Test data')\n",
"plt.xlabel('Percentage of removed stopwords', fontweight='bold')\n",
"plt.ylabel('Accuracy', fontweight='bold')\n",
"plt.savefig('plots_m1a/stopwordRemoval_m1a.png', bbox_inches = \"tight\")\n",
"plt.legend()\n",
"plt.savefig('plots_m1a/stopwordRemoval_m1a.png', bbox_inches = \"tight\")\n",
"plt.show()"
]
},
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
\begin{tabular}{lrr}
\toprule
{} & Precision & Recall \\
\midrule
WALKING & 0.760 & 0.536 \\
WALKING\_UPSTAIRS & 0.729 & 0.822 \\
WALKING\_DOWNSTAIRS & 0.651 & 0.795 \\
SITTING & 0.681 & 0.796 \\
STANDING & 0.877 & 0.628 \\
LAYING & 0.829 & 0.924 \\
\bottomrule
\end{tabular}
\begin{tabular}{lrr}
\toprule
{} & Precision & Recall \\
\midrule
WALKING & 0.861 & 0.593 \\
WALKING\_UPSTAIRS & 0.805 & 0.881 \\
WALKING\_DOWNSTAIRS & 0.694 & 0.894 \\
SITTING & 0.771 & 0.806 \\
STANDING & 0.912 & 0.804 \\
LAYING & 0.891 & 0.956 \\
\bottomrule
\end{tabular}
\begin{tabular}{lrrrrrr}
\toprule
{} & Top0 & Top1 & Top2 & Top3 & Top4 & Top5 \\
\midrule
Class0 & 0 & 0 & 143 & 87 & 266 & 0 \\
Class1 & 0 & 0 & 36 & 387 & 48 & 0 \\
Class2 & 0 & 0 & 334 & 49 & 31 & 6 \\
Class3 & 47 & 48 & 0 & 1 & 4 & 391 \\
Class4 & 334 & 54 & 0 & 6 & 1 & 137 \\
Class5 & 0 & 496 & 0 & 1 & 0 & 40 \\
\bottomrule
\end{tabular}
\begin{tabular}{lrrrrrr}
\toprule
{} & Top0 & Top1 & Top2 & Top3 & Top4 & Top5 \\
\midrule
Class0 & 1 & 0 & 353 & 145 & 727 & 0 \\
Class1 & 0 & 0 & 36 & 945 & 92 & 0 \\
Class2 & 1 & 0 & 881 & 79 & 24 & 1 \\
Class3 & 86 & 161 & 0 & 3 & 0 & 1036 \\
Class4 & 1105 & 3 & 0 & 2 & 1 & 263 \\
Class5 & 19 & 1345 & 0 & 0 & 0 & 43 \\
\bottomrule
\end{tabular}
......@@ -1145,7 +1145,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.3"
"version": "3.7.4"
}
},
"nbformat": 4,
......
{
"cells": [],
"metadata": {},
"nbformat": 4,
"nbformat_minor": 2
}
This diff is collapsed.
......@@ -25,7 +25,7 @@
{
"data": {
"text/plain": [
"4.0"
"5.0"
]
},
"execution_count": 6,
......@@ -38,7 +38,7 @@
"x= np.unique(y_train, return_counts=True)\n",
"labels = ['WALKING','WALKING_UPSTAIRS','WALKING_DOWNSTAIRS','SITTING','STANDING','LAYING']\n",
"print(np.where(y_train ==5))\n",
"y_train[32] "
"y_train[7197] "
]
},
{
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment