BookmarkSubscribeRSS Feed
jsberger
Obsidian | Level 7

I've been poking around for some time, but i just can't seem to find a way to capture the value of AT MEANS on an LSMEANS statement. SAS prints the mean value of the covariate in my model as part of the subtitle header.  Is there a way to capture this value to add to a reporting table?

2 REPLIES 2
PGStats
Opal | Level 21

You would have to request option E in the LSMeans statement and capture ODS table LSMeanCoef. Example:

 

proc glm data=sashelp.class plots=none;
class sex;
model weight = sex age sex*age;
lsmeans sex / e;
ods output lsmeancoef=coef;
run;
quit;

proc print data=coef; run;

 

PG
Rick_SAS
SAS Super FREQ

You can create a data set that contains any statistics that are produced by any SAS procedure. See

"ODS OUTPUT: Store any statistic created by any SAS procedure"

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

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
  • 2 replies
  • 1312 views
  • 0 likes
  • 3 in conversation