For several surveys, such as NHANES III, data for many files is available in ASCII format with SAS code. However, those of us, who want to use that data in R, it is little cumbersome to use first SAS, import data into it, then transfer data into a format that can be imported into R. I came across of this relatively new package, SAScii, that uses the ASCII format and then SAS code to directly import data into R. Quite nice.
1 comment:
hi rehan, if you're ever working with more current versions of nhanes, don't miss the easy-to-use scripts at
http://www.asdfree.com/search/label/national%20health%20and%20nutrition%20examination%20survey%20%28nhanes%29
i wrote SAScii as an absolute last resort for when the united states government provided nothing but ascii data and a sas script, but the cdc has recently started releasing the continuous nhanes as .xpt files -- so the `foreign` library's `read.xport` works on them just fine. ;)
Post a Comment