BookmarkSubscribeRSS Feed
cpeloquin
Fluorite | Level 6

i have a 3-level categorical character variable DOSE.

 

values are:

  • 1-5
  • 6-12
  • 13+

i would like to get estimates and 95% confidence intervals for "6-12" and 13+" where "1-5" is the reference group. what would be the syntax of the ESTIMATE statement?

 

many thanks for your help.

Christine

4 REPLIES 4
ballardw
Super User

Confidence interval has no meaning when discussing character variables. If you mean CI of a different numeric variable for each level of a character variable that is doable. Since reference an Estimate statement then perhaps you can share the current procedure code so we have some chance of seeing what other variables you are using.

PaigeMiller
Diamond | Level 26

@cpeloquin wrote:

i would like to get estimates and 95% confidence intervals for "6-12" and 13+" where "1-5" is the reference group. what would be the syntax of the ESTIMATE statement?

 


Assuming you really mean that you want 95% confidence intervals for the estimated model coefficients of "6-12" and 13+", these are given by default from PROC GENMOD, as can be seen in this example: 

https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.4/statug/statug_genmod_examples04.htm

 

If you want to compare these statistically, and get confidence intervals for the difference, you can get this from the LSMEANS statement with the CL option.


If that's not what you mean, then please explain further.

--
Paige Miller
StatDave
SAS Super FREQ

This should be posted in the Statistical Procedures Community rather than here. However, regardless of the distribution of your actual response variable, you can get the mean of it at each level of your Dose variable by specifying it the LSMEANS statement. Do not use the ESTIMATE statement. Make sure that Dose appears in the CLASS statement. Add the ILINK and CL options which will add columns in the LSMEANS table labeled "Mean" which has the mean estimate and confidence limits. For example:

 

lsmeans dose / ilink cl;

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 4 replies
  • 1113 views
  • 4 likes
  • 5 in conversation