diff --git a/Machine Learning with Iris Dataset.ipynb b/Machine Learning with Iris Dataset.ipynb index 453b0d3..3c979a0 100644 --- a/Machine Learning with Iris Dataset.ipynb +++ b/Machine Learning with Iris Dataset.ipynb @@ -449,6 +449,20 @@ "## Splitting The Data into Training And Testing Dataset" ] }, + { + "cell_type": "code", + "metadata": { + "id": "1RBGzEfbsuEY", + "colab_type": "code", + "colab": {} + }, + "source": [ + "from sklearn.linear_model import LogisticRegression # for Logistic Regression Algorithm\n", + "from sklearn import metrics" + ], + "execution_count": 0, + "outputs": [] + }, { "cell_type": "code", "execution_count": 21, @@ -466,6 +480,7 @@ } ], "source": [ + "from sklearn.model_selection import train_test_split\n", "train, test = train_test_split(iris, test_size=0.3) # our main data split into train and test\n", "# the attribute test_size=0.3 splits the data into 70% and 30% ratio. train=70% and test=30%\n", "print(train.shape)\n",