Renamed data munging to data wrnagling, fixed spacing between variables passed to confusion_matrix.

This commit is contained in:
Donne Martin 2015-03-27 06:36:23 -04:00
parent 53e0ae41c5
commit 89e04b3a89

View File

@ -1,7 +1,7 @@
{
"metadata": {
"name": "",
"signature": "sha256:fe04eef0e1b585f58c157fe7d1b587c987b3c88b090919bd351ebd0355debc73"
"signature": "sha256:d3ac53ac8ea0bf0eb2d46cbf71bcf8027770b97c83e25cd360eec2fedabc9a92"
},
"nbformat": 3,
"nbformat_minor": 0,
@ -31,7 +31,7 @@
"* Feature: Age\n",
"* Feature: Family Size\n",
"* Final Data Preparation for Machine Learning\n",
"* Data Munging Summary\n",
"* Data Wrangling Summary\n",
"* Random Forest: Training\n",
"* Random Forest: Predicting\n",
"* Random Forest: Prepare for Kaggle Submission\n",
@ -2442,14 +2442,14 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"## Data Munging Summary"
"## Data Wrangling Summary"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Below is a summary of the data munging we performed on our training data set. We encapsulate this in a function since we'll need to do the same operations to our test set later."
"Below is a summary of the data wrangling we performed on our training data set. We encapsulate this in a function since we'll need to do the same operations to our test set later."
]
},
{
@ -2741,7 +2741,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
"# Data munge the test set and convert it to a numpy array\n",
"# Data wrangle the test set and convert it to a numpy array\n",
"df_test = clean_data(df_test, drop_passenger_id=False)\n",
"test_data = df_test.values"
],
@ -2924,8 +2924,8 @@
"model_score = clf.score(test_x, test_y)\n",
"print (\"Model Score %.2f \\n\" % (model_score))\n",
"\n",
"confusion_matrix = metrics.confusion_matrix(test_y,predict_y)\n",
"print (\"Confusion Matrix \",confusion_matrix)\n",
"confusion_matrix = metrics.confusion_matrix(test_y, predict_y)\n",
"print (\"Confusion Matrix \", confusion_matrix)\n",
"\n",
"print (\" Predicted\")\n",
"print (\" | 0 | 1 |\")\n",