I am using Amelia 1.2-12 and R 2.9.1.
I am using a batch file for R that I haven't used in a year, and as I last recall, it worked without generating errors. But as I ran it this time, I got the following error. This occurred in imputation 1, "run" 1000-1200 (I tried a few times)....
> Error in dimnames(impdata$covMatrices)[[1]] <- prepped$theta.names :
> length of 'dimnames' [1] not equal to array extent
> In addition: Warning message:
> In amcheck(x = x, m = m, idvars = numopts$idvars, priors = priors, :
> You've set the polynomials of time to zero with no interaction with
> the cross-sectional variable. This has no effect on the imputation.
Although I've gotten decent with Amelia, I'm not quite sure what this means.
Best,
-Nathan
----------
Nathan A. Paxton, Ph.D.
Dept. of Government, Harvard University
napaxton AT fas DOT harvard DOT edu
http://www.fas.harvard.edu/~napaxton
========================================================
If every professor who backed a lunatic politician were to be sacked, half the interesting minds in academia would be lost.
- The Economist, 5 Jan 2002
A morning without coffee is like something without something else.
========================================================
Hi all,
I get a strange bug when using the "disperse" function with some
ordinal variables. The output of Amelia correctly gives these ordinal
variables integer values. However, they are stored in R as numeric
types. When I call "disperse", it calls the Amelia internal function
"amcheck". A few of the ordinal variables then fail the test
if (any(unique(na.omit(x[, i]))%%1 != 0))
and the disperse function fails.
Here's a simple test case that fails for me:
tmp <- data.frame(a=1:10000, b=round(rnorm(100000,0,3)))
tmp$b[1:2000*5] <- NA
a.out.try <- amelia(tmp, ords="b")
disperse(a.out.try)
David Hugh-Jones
Post-doctoral Researcher
Max Planck Institute of Economics, Jena
http://davidhughjones.googlepages.com
-
Amelia mailing list served by Harvard-MIT Data Center
[Un]Subscribe/View Archive: http://lists.gking.harvard.edu/?info=amelia
More info about Amelia: http://gking.harvard.edu/amelia
Dear all,
I am using Amelia II to impute but I have a question regarding one of
my variables which seems to pose a problem for multiple imputation
unless I can find a better coding rule:
I want to control for **compliance with treatment*** (binary variable
1,0) but I am not sure how to deal with the following:
say patient1 is under T1 in 1990 and complies, then dummy for T1=1 and
dummy for compliance=1
say patient2 is under T1 in 1999 and does not comply, then dummy for
T1=1 and dummy for compliance=0
But, then, say patient1 is NOT under T1 in 1980 (T1=0)
what value should I assign to compliance in this case? Should I leave
it as a missing -no value- (it makes sense but I will lose many
observations). On the other hand, it doesnt' make sense to assign 1 or
0 to compliance if there was nothing to comply (or fail to comply)
with in the first place.
Moreover, if I leave the compliance value as missing in this case,
when I use Amelia II the missing value for compliance will be imputed
and I am not sure this would be correct given that in reality
compliance did not exist b/c there was no treatment to comply with.
Thanks in advance,
Regards,
Helen A. Brown
-
Amelia mailing list served by Harvard-MIT Data Center
[Un]Subscribe/View Archive: http://lists.gking.harvard.edu/?info=amelia
More info about Amelia: http://gking.harvard.edu/amelia