It means that dat$v1, dat$v2, . . . are not columns in the data frame df

Specify the formula as v1 ~ v2+v2+v3+v4+v5+factor
Then (assuming that factor is a column object of the right length)
you should be fine.

John Maindonald             email: john.maindon...@anu.edu.au
phone : +61 2 (6125)3473    fax  : +61 2(6125)5549
Centre for Mathematics & Its Applications, Room 1194,
John Dedman Mathematical Sciences Building (Building 27)
Australian National University, Canberra ACT 0200.
http://www.maths.anu.edu.au/~johnm

> From: agent dunham <crossp...@hotmail.com>
> Date: 9 March 2011 3:47:10 AM AEDT
> To: r-help@r-project.org
> Subject: Re: [R] cv.lm syntax error
> 
> 
> Thanks for your answer, but I type the following: 
> 
>> dfmod.1 <- data.frame(dat$v1,dat$v2,dat$v3,dat$v4, dat$v5,factor)
> 
>> CVlm(df= dfmod.1, form.lm = formula(dat$v1 ~ dat$v2+dat$v3+ dat$v4+
>> dat$v5+ factor), m=3, seed=29, plotit=TRUE, printit =TRUE) 
> 
> Error en `[.data.frame`(df, , ynam) : undefined columns selected
> 
> What does it mean?
> 
> u...@host.com
> 
> --
> View this message in context: 
> http://r.789695.n4.nabble.com/cv-lm-syntax-error-tp3334889p3341767.html
> Sent from the R help mailing list archive at Nabble.com.


        [[alternative HTML version deleted]]

______________________________________________
R-help@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.

Reply via email to