[R-sig-eco] error in 'rownames?? - problem solved!

Megan Perry m.perry at uaf.edu
Wed Aug 26 23:54:43 CEST 2009


Hi,

Another student here got the problem figured out!

R was calling the variable "r" a factor, not a number, and then it 
couldn't fit an lme to a  factor response variable

Thank you!


Megan Perry

Alaska Cooperative Fish and Wildlife Research Unit - USGS

Institute of Arctic Biology

211 Irving I

PO Box 757020

University of Alaska Fairbanks

Fairbanks, AK 99775-7020

Office: 907-474-1133

Lab: 907-474-6740

m.perry at uaf.edu



Ben Bolker wrote:
>   this isn't a reproducible example.
>   Can you pull out a small subsample of the NPLW data set that
> gives the same error, dump it with dput(), and send to the list
> so that we can see what's going on?
>    Short of that, str(NPLW) *might* give us more of a hint.
>
>   Ben Bolker
>
>
> Megan Perry wrote:
>   
>> Hi,
>>
>> I am trying to analyze my data using a linear mixed effects model, using 
>> the nlme package. The model I am using is:
>>
>>  >LW<-lme(fixed=r ~ t,random = ~ 1 | s, method=c("ML"), data=NPLW)
>>
>> but, I am stumped with the error message:
>>
>> Error in `rownames<-`(`*tmp*`, value = c("1", "2", "3", "4", "5", "6",  :
>>  attempt to set rownames on object with no dimensions
>> In addition: Warning message:
>> In Ops.factor(y[revOrder], Fitted) : - not meaningful for factors
>>
>> Any help would be really appreciated!!
>>
>> Thanks,
>>
>> Megan
>>     
>
>
>



More information about the R-sig-ecology mailing list