title: R pROC precision
body: <p>I want to use the pROC package and find the precision. The problem is I DO NOT have the TP/TN/FP/FN values. Instead, i have the given probabilities for "Good" or "Poor" classification, likeso:</p>
  
  <pre><code>    GoodPoor=c("Good","Good","Poor","Poor","Good","Good","Poor","Poor","Good","Poor")
      prob1=c(0.73, 0.69, 0.44, 0.55, 0.67, 0.47, 0.08, 0.15, 0.45, 0.35)
  </code></pre>
  
  <p>so I create the roc() object giving my desired threshold</p>
  
  <pre><code>    M1=as.list(cbind(GoodPoor, prob1))
      roc1_t5&lt;-roc(GoodPoor ~ prob1, M1, thresholds = 0.5)
  </code></pre>
  
  <p>Now, I know that pROC package provides the specificity and sensitivity via roc1_t5$sensitivities and roc1_t5$specificities , but it doesn't seem to provide the precision. My question is: Is there a way to get the precision WITHOUT using other 'roc' packages? Thanks for your time</p>