Re: [R] ROCR - best sensitivity/specificity tradeoff?

From: Claudia Beleites <cbeleites_at_units.it>
Date: Thu, 07 Apr 2011 09:23:20 +0200

Christian,

> My questions concerns the ROCR package and I hope somebody here on
> the list can help - or point me to some better place.
>
> When evaluating a model's performane, like this:
>
>
> pred1<- predict(model, ..., type="response") pred2<-
> prediction(pred1, binary_classifier_vector) perf<- performance(pred,
> "sens", "spec")
>
> (Where "prediction" and "performance" are ROCR-functions.)
>
> How can I then retrieve the cutoff value for the
> sensitivity/specificity tradeoff with regard to the data in the model
> (e.g. model = glm(binary_classifier_vector ~ data, family="binomial",
> data=some_dataset)? Perhaps I missed something in the manual? Or do I
> need an entirely different approach for this? Or is there an
> alternative solution?

  1. look into the performance object, you find all values there
  2. have a look at this thread https://stat.ethz.ch/pipermail/r-help/attachments/20100523/51ec813f/attachment.pl http://finzi.psych.upenn.edu/Rhelp10/2010-May/240021.html http://finzi.psych.upenn.edu/Rhelp10/2010-May/240043.html

Claudia



R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Thu 07 Apr 2011 - 07:26:47 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 07 Apr 2011 - 08:00:27 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive