title: how to calculate sensitvity and specificity in cross-validation
body: <pre><code>scoring=['recall', 'precision']
  print("-----------------------------------------LR------------------------- 
  --------")
  clf = LogisticRegression()
  scores = cross_validate(clf, traindata, trainlabel, cv=3, scoring=scoring, 
  return_train_score=False)
  print(scores)
  
  print("precision")
  print(scores.keys()[2])
  print(np.mean(scores.values()[2]))
  print("Sensitivity")
  print(scores.keys()[3])
  print(np.mean(scores.values()[3]))
  </code></pre>
  
  <p>How to calculate specificity in the above code. The code calculates precision and recall. Recall is also called as sensitivity.</p>