[R] Amelia. Imputation of time-series data

2024-01-05 Thread Sorkin, John
Colleagues, I have started working with Amelia, with the aim of imputing missing data for time-series data. Although I have succeeded in getting Amelia to perform the imputation, I have not found any documentation describing how Amelia imputes time-series data. I have read the basic Amelia do

[R] Amelia

2017-05-27 Thread Johanna von Bahr
Hi, I have some trouble with Amelia. I run the following: all.data<-read.csv2("jldata2.csv", header = TRUE) summary(all.data) corp<-plm.data(all.data, cbind("country", "year")) data.mi <- Amelia::amelia(corp, idvars=1, ts=2, cs=3,intercs=FALSE,nom=4,5,6, 7, 8, 13, 14,19:27, 61 , bounds=bounds,

Re: [R] Amelia: Inputing Integers

2016-01-06 Thread Jim Lemon
Hi Lorenzo, Perhaps rounding the values in the imputed dataset? Jim On Thu, Jan 7, 2016 at 8:42 AM, Lorenzo Isella wrote: > Dear All, > I can provide a numerical example if needed. > My problem is the following: I am using amelia to input some missing > data in a dataset. > The problem is that

[R] Amelia: Inputing Integers

2016-01-06 Thread Lorenzo Isella
Dear All, I can provide a numerical example if needed. My problem is the following: I am using amelia to input some missing data in a dataset. The problem is that some columns consist of integer numbers only and amelia inputs some real numbers with decimals. Is there a way to tell amelia that cert

[R] Amelia: pool data from multiple imputated datasets - for descriptives

2014-08-06 Thread Rawson, Kerri
I used AmeliaView to create 5 imputed datasets. I want to pool the 5 imputed datasets into one to get pooled descriptive information (means, SD, min/max, etc) that is needed to calculate RCI scores (corrected for measurement error and practice effects). The formula to calculate RCI is ((X2 - X

Re: [R] Amelia, Zelig and latex in R

2013-08-18 Thread Christopher Desjardins
Hi, I am glad you could get it to work. I don't really know I usually just use xtable and any additional formatting I need done I do in my LaTeX editor. Perhaps there isn't a nice tex format out of the box for MI data. Once you write some nice code, you could keep reusing it or better yet package

Re: [R] Amelia, Zelig and latex in R

2013-08-18 Thread Francesco Sarracino
That's right! Your advice is in the right direction and with little adjustments it did the job. However, I admit it was tricky and the result looks a bit artisanal and needs some polishing that I will do by hand in the tex code. Is it possible that there is no way to get nicely latex formatted tabl

Re: [R] Amelia, Zelig and latex in R

2013-08-18 Thread Christopher Desjardins
Seems you're after the pooled results. Would the following work? library(Amelia) library(Zelig) library(xtable) data(africa) m = 10 imp1 <- amelia(x = africa,cs="country",m=m) imp2 <- amelia(x = africa,cs="country",m=m) lm.imputed1 <- zelig(gdp_pc ~ trade + civlib, model="ls",data = imp1) lm.i

Re: [R] Amelia, Zelig and latex in R

2013-08-18 Thread Francesco Sarracino
Dear Christopher, I have multiply imputed two data-set (let's say Africa1 and Africa2). Now I run 1 regression (let's call it: reg1) using the imputed data from Africa1 and 1 regression (let's call it: reg2) using the imputed data from Africa2. For these 2 regressions I use Zelig that automatical

Re: [R] Amelia, Zelig and latex in R

2013-08-17 Thread Christopher Desjardins
Oh and are you looking for just the summarized results over all the imputed runs? i thought you wanted them from each iteration. On Sat, Aug 17, 2013 at 11:38 AM, Christopher Desjardins < cddesjard...@gmail.com> wrote: > What do you mean by results? Do you want just the estimated parameters? >

Re: [R] Amelia, Zelig and latex in R

2013-08-17 Thread Christopher Desjardins
What do you mean by results? Do you want just the estimated parameters? And are you looking for one big table with all the estimated parameters from all imputation runs? Chris On Sat, Aug 17, 2013 at 11:18 AM, Francesco Sarracino wrote: > Hi Christopher, > thanks for your reply. Unfortunately,

Re: [R] Amelia, Zelig and latex in R

2013-08-17 Thread Christopher Desjardins
Does this do what you want? library(Amelia) library(Zelig) library(stargazer) library(xtable) data(africa) m = 10 imp1 <- amelia(x = africa,cs="country",m=m) imp2 <- amelia(x = africa,cs="country",m=m) lm.imputed1 <- zelig(infl ~ trade + civlib, model="ls",data = imp1) lm.imputed2 <- zelig(infl

Re: [R] Amelia, Zelig and latex in R

2013-08-17 Thread Francesco Sarracino
Hi Christopher, thanks for your reply. Unfortunately, that's not what I am looking for. I would like to have a table with the results of the two models (lm.imputed1 and lm.imputed2) in two separate columns. According to stargazer syntax I should type something like: stargazer(lm.imputed1, lm.impute

[R] Amelia, Zelig and latex in R

2013-08-17 Thread Francesco Sarracino
Dear listers, I am running some OLS on multiply imputed data using Amelia. I first imputed the data with Amelia. than I run a OLS using Zelig to obtain a table of results accounting for the multiply imputed data-sets. And I'd like to do this for various models. Finally, I want to output all the mo

Re: [R] Amelia algorithm

2013-01-12 Thread Matt Blackwell
Hi Martin, I helped to develop Amelia, so I can try to take a shot. In a non-mathematical way, Amelia works by filling in missing values with imputed values that are consistent with the observed relationships in the data, plus some random noise. Thus, Amelia creates multiple imputed datasets that

Re: [R] Amelia algorithm

2013-01-07 Thread zGreenfelder
On Mon, Jan 7, 2013 at 4:29 PM, Martin wrote: > Dear all. > > First of all, my english isn't verry good, but I hope I can convey my concern. > I've a general question about the Amelia algorithm. I'm no mathematician or > statistician, but I had to use R and impute and analyse some data, and Amelia

[R] Amelia algorithm

2013-01-07 Thread Martin
Dear all. First of all, my english isn't verry good, but I hope I can convey my concern. I've a general question about the Amelia algorithm. I'm no mathematician or statistician, but I had to use R and impute and analyse some data, and Amelia showed results that fitted my expectations. I'll have t

Re: [R] Amelia imputation - column grouping

2012-10-30 Thread Jose Iparraguirre
e number of imputations). Jose From: r-help-boun...@r-project.org [r-help-boun...@r-project.org] On Behalf Of Elisa D'Arcangelo [darcangelo.el...@googlemail.com] Sent: 30 October 2012 13:35 To: r-help@r-project.org Subject: [R] Amelia imputation - col

[R] Amelia imputation - column grouping

2012-10-30 Thread Elisa D'Arcangelo
Hi everybody, I am quite new to data imputation, but I would like to use the R package ' Amelia II: A Program for Missing Data '. However, its unclear to me how the input for amelia should look like: I have a data frame consisting of numerous coulmns, which represent different experimental condi

Re: [R] Amelia error

2012-04-18 Thread Gaurav Sood
Easily fixed, Peter - str(ad04) 'data.frame': 1195 obs. of 15 variables: $ V040001 : num 1 2 3 4 5 6 7 8 9 10 ... $ insurance: num 7 2 4 1 5 2 7 1 5 5 ... $ jobs : num 7 3 4 1 6 5 7 5 4 7 ... $ services : num 5 2 5 1 5 2 7 1 4 7 ... $ ss : num 2 2 2 1 2 1 2 1 1 3 ... $ wom

Re: [R] Amelia error

2012-04-18 Thread Gaurav Sood
Sarah - I have all the vars.. they all look sensible. I have been able to trace the problem to NAs in the nominal variable, which is a bit strange. The error that the program spits out is a class logical equating error in presence of NAs etc. and hence was my hunch that it was a bug. On Wed, A

Re: [R] Amelia error

2012-04-18 Thread Peter Ehlers
On 2012-04-18 11:18, Gaurav Sood wrote: Using: Amelia::amelia R version: 2.15 OS: Windows 7 Enterprise data = National Election Studies (cross-sectional); mostly ordinal variables, some nominal summary(ad04) insurance jobs services sswomen Min.

Re: [R] Amelia error

2012-04-18 Thread Sarah Goslee
Hi, On Wed, Apr 18, 2012 at 2:18 PM, Gaurav Sood wrote: > Using: Amelia::amelia > > R version: 2.15 > OS: Windows 7 Enterprise > > data = National Election Studies (cross-sectional); mostly ordinal > variables, some nominal > > summary(ad04) > >   insurance          jobs          services        

Re: [R] Amelia error

2012-04-18 Thread David Freedman
I've had a little experience using the package, Amelia. Are you sure that your nominal variables - race, south, etc - are in your ad04 data frame ? David Freedman -- View this message in context: http://r.789695.n4.nabble.com/Amelia-error-tp4568455p4568600.html Sent from the R help mailing lis

Re: [R] Amelia error

2012-04-18 Thread Gaurav Sood
Using: Amelia::amelia R version: 2.15 OS: Windows 7 Enterprise data = National Election Studies (cross-sectional); mostly ordinal variables, some nominal summary(ad04) insurance jobs services sswomen Min. :1.000 Min. :1.000 Min. :1.000 Min

Re: [R] Amelia error

2012-04-18 Thread Sarah Goslee
Do you mean the Amelia package? Or a function named Amelia()? What is your OS and version of R and package? What are the commands you are using? What do your data look like? Can you provide a reproducible example? Did you read the posting guide? Your problem doesn't "seem like a bug" rather t

[R] Amelia error

2012-04-18 Thread Gaurav Sood
Hi, Encountering the following error using Amelia - Error in if (sum(non.vary == 0)) { : argument is not interpretable as logical In addition: Warning message: In FUN(X[[34L]], ...) : NAs introduced by coercion Seems like a bug. __ R-help@r-project.