I am analyzing a survey data with a raw sample size of about 2.7 million, when I run the proc survey procedures, the sample size comes down to about 2 million and I am sure this is not explained by the missing data because I ran the proc freq and the missing data were very small and the sample size with the normal proc procedures was 2.7 million. Does anyone know why?
Thanks.
If you're specifying design variables (STRATA and/or CLUSTER variables), maybe some of these values are missing. Observations with missing STRATA or CLUSTER values are excluded from the analysis unless you specify the MISSING option. Also, observations with missing or negative WEIGHT values are excluded. There's more information in the survey proc documentation section Missing Values.
See if you can observe the effect with a small subset (~100 observations) of your data. If yes, post that here (in a data step with datalines, see my footnotes), and your code, so we can recreate the issue.
@olabuh wrote:
I am analyzing a survey data with a raw sample size of about 2.7 million, when I run the proc survey procedures, the sample size comes down to about 2 million and I am sure this is not explained by the missing data because I ran the proc freq and the missing data were very small and the sample size with the normal proc procedures was 2.7 million. Does anyone know why?
Thanks.
What specific analysis are you performing? What specific SAS PROCs are you using?
If you're specifying design variables (STRATA and/or CLUSTER variables), maybe some of these values are missing. Observations with missing STRATA or CLUSTER values are excluded from the analysis unless you specify the MISSING option. Also, observations with missing or negative WEIGHT values are excluded. There's more information in the survey proc documentation section Missing Values.
Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!
Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.