[R] problems using mice()

From: Birgitle <birgit.lemcke_at_systbot.uzh.ch>
Date: Wed, 09 Jul 2008 02:58:57 -0700 (PDT)

R 2.7.2
PPC Mac OS X 10.4.11
library mice 1.13.1

I try to use mice for multivariate data imputation. My variables are numeric, factors, count data, ordered factors.

First I created a vector for the methods to use with each variable

      ImpMethMice<-c(rep("logreg", 62), rep("polyreg",1), rep("norm",12), rep("polyreg",12))

next step was

     Test<-mice(df, im=ImpMethMice)

I got the following error message:

iter imp variable
  1 1 variablenameFehler in impute.logreg(c(2L, 2L, 2L, 2L, 2L, 2L, 2L, 1L, 2L, 2L, 1L, 2L, :
  Dimensionen [Produkt 119] passen nicht zur Länge des Objektes [122] Zusätzlich: Es gab 50 oder mehr Warnungen (Anzeige der ersten 50 mit warnings())

 1 1 variablenameError in impute.logreg(c(2L, 2L, 2L, 2L, 2L, 2L, 2L, 1L, 2L, 2L, 1L, 2L, :
  dimensions [product 119] don`t match lenght of object [122] Additional: 50 or more warnings (show first 50 with warnings())

    warnings()

  1. In any(predictorMatrix[j, ]) ... : wandle Argument des Typs 'double' nach boolesch
  2. In any(predictorMatrix[j, ]) ... : transform argument of type 'double' to boolesch

I would be very happy if somebody could help me to fix this. Thanks in advance.

B.



The art of living is more like wrestling than dancing. (Marcus Aurelius)
-- 
View this message in context: http://www.nabble.com/problems-using-mice%28%29-tp18358093p18358093.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
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.
Received on Wed 09 Jul 2008 - 10:14:01 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 09 Jul 2008 - 11:31:49 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive