BookmarkSubscribeRSS Feed
rickw
Calcite | Level 5
Hi,

I want to add noobs and rsquare to parameter estimates.

I know we could use ODS parameter estimates to create the parameter estimates table. However, I want No of obs used, read and Rsqaure also added to this table .. Is there any option in ODS that does it ?

I am using the following code:

ods listing close;
ods output ParameterEstimates=Parameter_Estimates(drop = model dependent df label);

proc reg data = temp;
model &dep = &indep_vars;
by &group_by;
run;

ods listing;


Thank you.
6 REPLIES 6
Paige
Quartz | Level 8
You would need to output other ODS tables that contain R-square and N
rickw
Calcite | Level 5
Thank you. ODS did the job 🙂
rickw
Calcite | Level 5
Hi,

When I am running regression using by group processing, SAS stops working when there are less no. of observations in a group.


Is there any way I could tell sas to continue executing for the remainder of the observations rather than stopping.??

Thanks.
Paige
Quartz | Level 8
I don't observe this.

Could you provide more details? Or a copy of the log?

What do you mean by "stops working"?
What do you mean by "less no. of observations in a group"?
rickw
Calcite | Level 5
I get the following error:

ERROR: No valid observations are found.
NOTE: The above message was for the following BY group:
Segment=a1 HR_Class=sec2
ERROR: No valid observations are found.
NOTE: The above message was for the following BY group:
Segment=a1 HR_Class=sec3
ERROR: No valid observations are found.
NOTE: The above message was for the following BY group:
Segment=a3 HR_Class=sec1
NOTE: Interactivity disabled with BY processing.
NOTE: PROCEDURE REG used (Total process time):
real time 3.54 seconds

However, I see that my program produces the files that I need to export even though the error message is there. Are the results outputted correct in this case??

Thanks.
Paige
Quartz | Level 8
> I see that my program produces the files that I
> need to export even though the error message is
> there. Are the results outputted correct in this
> case??

They are correct in my example.

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 Bayesian Analysis?

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.

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