Help using Base SAS procedures

"WHERE" statement into Proc GLM

Accepted Solution Solved
Reply
Frequent Contributor
Posts: 103
Accepted Solution

"WHERE" statement into Proc GLM

Hi my friends:

I have one question, as always haha:

I have many data to use into Proc GLM, and i need to exclude some data (Discrepant data) from the tail and head, so im trying to use WHERE statement like that:

Proc GLM:

Where Polen_Gr < 250; (meaning that i'm gonna use just data under 250)

And i would like to Add that i want to use data above 100 and i dont know how to do it

Resuming: I JUST NEED the interval "X"

100>X>250


Thanks


Accepted Solutions
Solution
‎05-27-2015 10:02 AM
Super User
Super User
Posts: 7,078

Re: "WHERE" statement into Proc GLM

Posted in reply to jonatan_velarde

Did you try what you posted?

These three different methods should all do the same thing.

where 100 < Polen_Gr < 250 ;

where (100 < Polen_Gr ) and (Polen_Gr < 250) ;

where 100 < Polen_Gr ;

where also Polen_Gr < 250 ;

View solution in original post


All Replies
Contributor
Posts: 44

Re: "WHERE" statement into Proc GLM

Posted in reply to jonatan_velarde

You can use where clause in data= -clause

Proc Glm data=have(where=(Polen_gr lt 250));

Super User
Posts: 5,518

Re: "WHERE" statement into Proc GLM

Posted in reply to jonatan_velarde

To apply both boundaries:

where 100 < Polen_Gr < 250;

Solution
‎05-27-2015 10:02 AM
Super User
Super User
Posts: 7,078

Re: "WHERE" statement into Proc GLM

Posted in reply to jonatan_velarde

Did you try what you posted?

These three different methods should all do the same thing.

where 100 < Polen_Gr < 250 ;

where (100 < Polen_Gr ) and (Polen_Gr < 250) ;

where 100 < Polen_Gr ;

where also Polen_Gr < 250 ;

🔒 This topic is solved and locked.

Need further help from the community? Please ask a new question.

Discussion stats
  • 3 replies
  • 248 views
  • 0 likes
  • 4 in conversation