title: Scoring predictions in sklearn (Python machine learning)
body: <p>I'm going through the following IPython Notebook which analyzes the <a href="http://nbviewer.jupyter.org/github/rhiever/Data-Analysis-and-Machine-Learning-Projects/blob/master/example-data-science-notebook/Example%20Machine%20Learning%20Notebook.ipynb" rel="nofollow noreferrer">Iris dataset</a></p>
  
  <p>At one point in the notebook the author builds the following model:</p>
  
  <p><a href="https://i.stack.imgur.com/X592b.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/X592b.png" alt="enter image description here"></a></p>
  
  <p>At this point, I became very confused. What is going on in the last line?
  From what I learned, you should create a prediction based on the model and then compare that prediction to the <code>y_test</code> values.</p>
  
  <p>I would have done the following:</p>
  
  <pre><code>predictions = decision_tree_classifier.predict(X_test)
  from sklearn.metrics import classification_report
  print classification_report(y_test, predictions)
  </code></pre>
  
  <p>What is going on when the author generates a score based on the <code>testing_inputs</code> and the <code>testing_classes</code>?</p>