title: In the numpy std calculation , np.std(y_test == y_test_predict), what is the meaning of comparing the test split and predicted result
body: <p>Pl look at the K Neight classification ML algorithm using Python</p>
  
  <pre><code> for i in range (0,Ks):
       neigh = KNeighborsClassifier(n_neighbors = i+1).fit(x_train,y_train)
       y_test_predict = neigh.predict(x_test)
       mean_acc[i] = metrics.accuracy_score(y_test,y_test_predict)
       std_acc[i] = np.std(y_test == y_test_predict)/np.sqrt(y_test_predict.shape[0])
  </code></pre>
  
  <p>I have 1 questions
  (1)what is the meaning of the this statement "np.std(y_test == y_test_predict)". what will the output of the the operation y_test == y_test_predict and why that is being passed as an argument to the std() lib</p>
  
  <p>also what is the logic behind the standard deviation formula</p>
  
  <pre><code> std_acc[i] = np.std(y_test == y_test_predict)/np.sqrt(y_test_predict.shape[0])
  </code></pre>
  
  <p>(2) why std dev accuracy is computed as below:</p>
  
  <pre><code> np.std(y_test == y_test_predict)/np.sqrt(y_test_predict)
  </code></pre>