[R] lmer() vs. "fixed effects" regression

2009-09-24 Thread jjh21
Hi, First, some quick terminology I am using: Fixed effects = model with unit dummy variables Random effects = model without unit dummy variables, integrating unit-level variance out of likelihood I am confused about the difference between the multilevel modeling framework of lmer() and a "fixed

Re: [R] Hmisc package: deff() command's formula for the design effect

2009-05-28 Thread jjh21
One additional question: It seems that in practice the design effect is often calculated on the response variable or on individual predictor variables. I have some OLS models using observational data that are clustered. Does it make sense to calculate the design effect on the residuals of one of

Re: [R] Clustered data with Design package--bootcov() vs. robcov()

2009-05-23 Thread jjh21
Another question related to bootcov(): A reviewer is concerned with the fact that bootstrapping the standard errors does not give the same answers each time. What is a good way to address this concern? Could I bootstrap, say, 100 times and report the mean standard error of those 100 estimates? I

[R] Hmisc package: deff() command's formula for the design effect

2009-05-06 Thread jjh21
Hello, I have been using the Hmisc package's deff() command for some research with clustered data. I noticed that the formula to calculate the design effect seems a bit different. The formula for the DE is: 1 + rho*(B - 1) In most resources I have seen the formula for B to simply be the average

[R] R graph into MS Word: which format to use?

2009-04-20 Thread jjh21
Hello, The journal I am publishing in requires MS Word files. What is my best option for getting a high quality image of a graph done in R into Word? JPEG? Postscript? Thanks. -- View this message in context: http://www.nabble.com/R-graph-into-MS-Word%3A-which-format-to-use--tp23133745p2313374

[R] Clustered data with Design package--bootcov() vs. robcov()

2009-04-12 Thread jjh21
Hi, I am trying to figure out exactly what the bootcov() function in the Design package is doing within the context of clustered data. From reading the documentation/source code it appears that using bootcov() with the cluster argument constructs standard errors by resampling whole clusters of ob

[R] Simulate binary data for a logistic regression Monte Carlo

2009-04-07 Thread jjh21
Hello, I am trying to simulate binary outcome data for a logistic regression Monte Carlo study. I need to eventually be able to manipulate the structure of the error term to give groups of observations a random effect. Right now I am just doing a very basic set up to make sure I can recover the p

[R] Choosing how to vary slopes and intercepts in a hierarchical model

2009-02-25 Thread jjh21
Hi, Is there any set of rules for deciding exactly how to vary slopes and intercepts in a HLM? I have NOMINATE scores from the senate over three years. So I have multiple observations of senators, nested in states, nested in years. Covariates include level-1 (senator in a specific year) variables

[R] Difference between GEE and Robust Cluster Standard Errors

2009-02-18 Thread jjh21
Hello, I know that two possible approaches to dealing with clustered data would be GEE or a robust cluster covariance matrix from a standard regression. What are the differences between these two methods, or are they doing the same thing? Thanks. -- View this message in context: http://www.nabb

[R] What is the R equivalent of STATA's 'drop' command?

2009-02-09 Thread jjh21
Hello, I am trying to do some data cleaning in R. I need to drop observations that take on certain values of a variable. In STATA I might type something like: drop if == 3 drop if == 4 Is there an R equivalent of this? I have tried playing around with the subset command, but it seems a bit cl

[R] Creating clustered data with a random effect for a MC analysis

2009-01-23 Thread jjh21
I am trying to create a data set in R with a random cluster effect. I would like to do it so I can set the intraclass correlation coefficient (ICC) in the data generating process. I have tried a few methods, but cannot seem to get enough control over the ICC. I have been estimating the ICC using t

[R] 'equivalent' sign in plot title

2009-01-08 Thread jjh21
Hello, I would like to add the 'equivalent' sign (i.e., three horizontal lines, almost like an equal sign) to a plot. Does R have anything like the LaTeX command '\equiv' that I could put into a plot title? Thanks -- View this message in context: http://www.nabble.com/%27equivalent%27-sign-in-

Re: [R] Need help creating spatial correlation for MC simulation

2008-09-22 Thread jjh21
at may be what you are looking for. Case > not, > please let me know and may be we can improve some solution. > > Best wishes, > > miltinho astronauta > brazil > > > > On Wed, Sep 17, 2008 at 7:36 PM, jjh21 <[EMAIL PROTECTED]> wrote: > >>

[R] Need help creating spatial correlation for MC simulation

2008-09-17 Thread jjh21
I want to create a dataset in R with spatial correlation (i.e. clustering) built in for a linear regression analysis. Any tips on how to do this? Thanks. -- View this message in context: http://www.nabble.com/Need-help-creating-spatial-correlation-for-MC-simulation-tp19542145p19542145.html Sent