[R] Fwd: ad. Amelia Package for R: Error; contrasts can be applied only to factors with 2 or more levels

2015-01-10 Thread Joanna Cieslak
Hello, I am trying to use the multiple imputation method to replace NAs in the columns denoting net recalled salary (variable q32) from the file downloadable here: http://www.ads.org.pl/pobieranie-zbioru-danych.php?id=91 It is a survey with 17497 observations of 1681 variables, so I am reducing

[R] Error: contrasts can be applied only to factors with 2 or more levels

2013-05-16 Thread Belair, Ethan D
I have a dataframe that I am attempting to analyze using the lmList() function in package lme4. I'm using this funciton to select which parameters in this model wqarrant random effects. I have a subset of the data below. I input data and change class of necessary items so that I have several

Re: [R] Error: contrasts can be applied only to factors with 2 or more levels

2013-05-16 Thread John Kane
Beautiful first question. 333 ch.list - lmList(h12~spp+t+w+l+inih|id, data=mydata) Should that not be data= chm John Kane Kingston ON Canada -Original Message- From: ebel...@purdue.edu Sent: Thu, 16 May 2013 15:05:35 + To: r-help@r-project.org Subject: [R] Error: contrasts

Re: [R] Error: contrasts can be applied only to factors with 2 or more levels

2013-05-16 Thread arun
Hi, The example dataset only shows 1 level for ID. chm   id site plot rx rxg rxl t w l spp inid inih d09  d10  d11  d12 h09 h10 1  1  C-H 2002  1   1  Mn N N 14.55  ac  9.6 74.5 9.6 13.0 13.5 14.2  96 109 2  1  C-H 2002  1   1  Mn N N 14.55  ac  7.4 69.5 6.0  9.8   NA 10.7  72  77 3  1  C-H

Re: [R] Error: contrasts can be applied only to factors with 2 or more levels

2013-05-16 Thread Rolf Turner
In the example data that you provide, the factor id has only one level, namely 1. Your example date appears to be just the head (first 6 rows) of your real data, so this may not be the real story. It's hard to tell from what you've said. Also see in line below. cheers, Rolf

[R] Error; contrasts can be applied only to factors with 2 or more levels

2012-08-14 Thread grace
Hi, I have been running the same code without problem for the last few days, changing data sets etc with no issue. Today I changed the covariates for the model and am now getting this error message: Error in `contrasts-`(`*tmp*`, value = contr.funs[1 + isOF[nn]]) : contrasts can be applied

Re: [R] Error; contrasts can be applied only to factors with 2 or more levels

2012-08-14 Thread R. Michael Weylandt
On Tue, Aug 14, 2012 at 5:54 AM, grace sololo...@hotmail.com wrote: Hi, I have been running the same code without problem for the last few days, changing data sets etc with no issue. Today I changed the covariates for the model and am now getting this error message: Error in