Thanks for your help so far, everyone. Thomas: I haven't looked very deep into the survey package yet, so I don't know if what I'm looking for is actually missing or if I just haven't found it yet. What is "missing", from my point of view at the moment, is some kind of global weighting function that allows me to set a weight and then just perform different kinds of analyses without thinking about it any more. (... this must be R's "steep learning curve" that I read about).
I'll try to describe what I want to do: I'll be working with the European Social Survey datasets (for my MA thesis). The data have to be weighted before doing any kind of analyses because the sample sizes in the different countries aren't proportional to total population sizes. Analyses I probably will do include: contingency tables, measures of association (Cramer's V), factor analysis, linear regression. I've used SPSS so far and thus haven't ever had to look very deep into what 'weighting' means, exactly. Vera 2010/1/16 Thomas Lumley <tlum...@u.washington.edu>: > On Fri, 15 Jan 2010, vivi ane wrote: > >> is there a function in R equivalent to the "weight by"-command in SPSS? >> I'm working with survey datasets and the data need to be weighted by a >> survey/ probability/ design weight (to compensate for different >> probabilities to be included in the sample in each country). The >> weight variables are included in the datasets. >> >> I did find functions in the Hmisc and survey packages that might fit >> some of my needs but I need to do a bunch of procedures for all of >> which the data must be weighted, as far as I can see. (I'm quite new >> to R and the prospect of having to write my own functions for all of >> them is really scaring me ;)) >> > > The survey package covers quite a wide range of analyses. Can you be more > specific about what you think is missing? > > -thomas > > > Thomas Lumley Assoc. Professor, Biostatistics > tlum...@u.washington.edu University of Washington, Seattle > > ______________________________________________ R-help@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.