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.

Catch up on SAS Innovate 2026

Nearly 200 sessions are now available on demand with the SAS Innovate Digital Pass.

Explore 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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 6 replies
  • 3459 views
  • 0 likes
  • 2 in conversation