BookmarkSubscribeRSS Feed
saslove
Quartz | Level 8

I came across this question at work. I would like to have your input. I have never done monte carlo and i am a newbie. So, please excuse my dumbness!

I want the standard error from model , error estimate and confidence interval on predicted number of response variable. I want to do simulation (i was told multiply predicted probability by case weight and sum it all up and repeat 1000 times). I need 2.5th and 97.5th % confidence interval and errors on percent predictions.  PROC SURVEYLOGISTIC was used for analysis. I then used xbeta and stdxbeta to get the linear predictors and standard error of linear predictor. I back transformed the values. I'm trying to use PROC MCMC here. So, I assume standard error is normally distributed and resample error 1000 times. Also, I need a confidence interval on full prediction and sample error on output.


I would like some help here as to use PROC MCMC for getting the desired output. These are just the notes I took from our meeting.

This is the surveylogistic code.

proc surveylogistic data=outboot;

       where var1="abc" and var2 in ("abc") and var3 in (11, 13) and var4>15

and var6>1999 and  85>var7>15;

       format var varfmt..;

       stratum strat;

       cluster psu;

       weight weight;

       class var var2  /param=ref;

       model resp (desc)=vara varb varc vard

/ Rsquare ;

output out=outall predprobs=individual xbeta=predval stdxbeta=sepred;

run;

How do I use PROC MCMC to get confidence intervals and standard errors. I need CI on full prediction and need to sample error on output. Please help.

1 REPLY 1
saslove
Quartz | Level 8

Anyone done anything similar????

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 1217 views
  • 0 likes
  • 1 in conversation