[R] "prob" in predict(randomForest)

Liaw, Andy andy_liaw at merck.com
Tue May 5 14:17:06 CEST 2009


In short, yes.

Andy 

From: Haring, Tim (LWF)
> 
> Hi at all,
> 
> maybe this question is quite simple for a statistician, but 
> for me it is not. After reading a lot of mail in the R-help 
> archive I`m still not quite sure I get it. 
> When applying a randomForest to a new dataset with 
> predict(randomForest) I have the option to get the output as 
> probability (classification problem):
> predict(myrf,...,type="prob")
> I would like to know how I have to understand this output. 
> Are this values the probability of an observation belonging 
> to a predicted class? Say, I have a data-point as newdata, my 
> rf-model predicts Class A and the probability is 0,12301. 
> Does this mean that this data-point belongs to class A only 
> with a probability of 12%?
> 
> Thanks for every hint.
> 
> TIM
> 
> Just as a matter of form: I´m using R version 2.8.1, 
> randomForest package 4.5-28, OS: WinXP
> 
> --------------------------------------------------------------
> --------------------- 
> Tim Häring
> Bavarian State Institute of Forest Research 
> Department of Forest Ecology
> Am Hochanger 11
> D-85354 Freising
> 
> E-Mail: tim.haering at lwf.bayern.de
> http://www.lwf.bayern.de
> 
> ______________________________________________
> 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.
> 
Notice:  This e-mail message, together with any attachme...{{dropped:12}}




More information about the R-help mailing list