---------- Forwarded message ----------
From: Θωμας <blitskasvonarta(a)gmail.com>
Date: 2009/5/3
Subject: Re: [amelia] Error in amelia(data = x) : argument "x" is missing,
with no default"
To: Matt Blackwell <mblackwell(a)gmail.com>
Thank you Dr Blackwell,
First thank you for your time and for letting me use Amelia.
I still experience problems:
Lets say the file I need to impute is called mis (attached) and is saved as
a txt file on the desktop.
*From the R environment *:
misi<-read.table('C:\\Documents and
Settings\\thomas\\Desktop\\mis.txt',
header=T)
output<-amelia(x=misi, empri=10,ords=c(3,4))
this gives me the error : "Error in amelia(x = misi, empri = 10, ords =
c(3,4)) : unused argument(s) (x = list(Patient = c(1, 1, 1, 1, 1 etc...
*if I do*
output<-amelia(x, empri=10,ords=c(3,4)) then it
produces imputations
*However next at zelig*
z.out <- zelig(lm(IOP~ICP+CVP+CONCORDANCE), data =
output$imputations) .
I am getting the error "Error in eval(expr, envir,
enclos) : object "IOP"
not found"
*Following the instructions at AmeliaView()* and z.out <-
zelig(lm(IOP~ICP+CVP+CONCORDANCE), data = output$imputations) I am getting
the error "Error in eval(expr, envir, enclos) : object "IOP" not
found"
Attached is the example file I am using.
Once again thank you for your kindness to let me use Amelia.
Regards,
Tom Spentzas, ΜD, MS
Ass Prof. at UT
On Sun, May 3, 2009 at 2:02 PM, Matt Blackwell <mblackwell(a)gmail.com> wrote:
Hello,
The syntax of Amelia has changed in recent versions. You can run your
code like so:
output<-amelia(x=x, empri=10,ords=c(3,4))
z.out <- zelig(***, data = output$imputations)
where you would replace *** with your model and settings.
If you call AmeliaView() from an R session, you can use the output
option "Hold in R memory". Afterward, you can click on "File" then
"Exit Amelia." Once you are back at the R prompt, you should be able
to find your Amelia output. By default it is named "outdata." In order
to use Zelig:
z.out <- zelig(***, data = outdata$imputations)
I hope this helps. Let us know if you have any more problems.
Thanks for using Amelia!
matt.
On Sun, May 3, 2009 at 11:23 AM, Hylar <blitskasvonarta(a)gmail.com> wrote:
I am trying to understand how zelig can peak up
the imputation files
generated by amelia . There isn't any example on the ppt course.
I used output<-amelia(data=x, empri=10,ords=c(3,4)) and I received an
error
message "Error in amelia(data = x) :
argument "x" is missing, with no
default"
Then I used the AmeliaView () I saved the 5 files on the desktop but I do
not know how to pick them up with the zelig.
I will appreciate a simple example - first with "output<-amelia(data=x,
empri=10,ords=c(3,4))" and second with "AmeliaView()"
Thank you again,
Tom Spentzas, MD MD
Ass Professor Univ of Tennessee.