[R] R question [Broadcast]

Liaw, Andy andy_liaw at merck.com
Fri May 4 20:52:24 CEST 2007


Bill,

A couple more points:

1. Please use an informative subject line.  I'd deleted the original 
   post w/o reading if I didn't catch Marc's reply.

2. Are you sure you have "bivariate" response?  To me "bivariate" means
   two variables, and randomForest surely does not handle that (at least
   for now).

Andy   

From: Marc Schwartz
> 
> On Fri, 2007-05-04 at 12:05 -0500, Bill Vorias wrote:
> > I had a question about Random Forests.  I have a text file with 10
> > dichotomous variables and a bivariate response vector.  I 
> read this file
> > into R as a data frame, and then used the command 
> "randomForest(Response ~.,
> > dataset, etc.." where "Response" is the column header of 
> the response
> > variable and "dataset" is the name of the data frame.  I 
> get an error that
> > says "Response" not found.  I was looking at the Iris data 
> example in the R
> > help files, and it seems like this is exactly what they 
> did.  Do you have
> > any suggestions? Thanks.
> 
> 
> R you sure that you have correctly specified the column and data frame
> names in the call to randomForest()?
> 
> Be sure to check for typos, including capitalization.
> 
> You can use:
> 
>   ls()
> 
> to check for the current objects in your working environment 
> and you can
> then use:
> 
>   str(YourDataFrame)
> 
> or 
> 
>   names(YourDataFrame)
> 
> to display information about the detailed structure and/or 
> column names,
> respectively, in the data frame that you created from the 
> imported data.
> 
> HTH,
> 
> Marc Schwartz
> 
> ______________________________________________
> R-help at stat.math.ethz.ch 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 attachments,...{{dropped}}



More information about the R-help mailing list