Statistical Procedures

Programming the statistical procedures from SAS
BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
yael
Quartz | Level 8

Hello,

 

I have the following code:

proc means data=sasuser.sasfile010916 mean median std min max;
where firmdefi=1 and firmdefi=2;
var equity TAssets Sales;
class firmdefi;
run;

 

The log indicate NOTE: No observations were selected from data set SASUSER.SASFILE010916.

 

There is data that relate to firmdefi 1 or 2 and I do not understand what is my mistake?

 

Thanks for any help!!!

1 ACCEPTED SOLUTION

Accepted Solutions
Astounding
PROC Star

Logically, it is not possible for FIRMDEFI to equal 1 and 2 at the same time.  Instead of using AND, your WHERE statement could switch to OR.  Alternatively:

 

where firmdefi in (1, 2);

View solution in original post

1 REPLY 1
Astounding
PROC Star

Logically, it is not possible for FIRMDEFI to equal 1 and 2 at the same time.  Instead of using AND, your WHERE statement could switch to OR.  Alternatively:

 

where firmdefi in (1, 2);

sas-innovate-white.png

Join us for our biggest event of the year!

Four days of inspiring keynotes, product reveals, hands-on learning opportunities, deep-dive demos, and peer-led breakouts. Don't miss out, May 6-9, in Orlando, Florida.

 

View the full agenda.

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
  • 1466 views
  • 1 like
  • 2 in conversation