Can i filter and sort for 2 variables?

Reply
New Contributor
Posts: 4

Can i filter and sort for 2 variables?

In the following example is there a way to filter out where Variety A & B appear in the location? (Location 2&3) I am working witha large speadsheet and many varieties and locations that I need to filter for like locations?

Location     Variety     Size

1                    A          25

2                    A          30

3                    A          30

4                    A          35

2                    B          22

3                    B          25

5                    B          50

2                    C          15

3                    C          10

4                    C          15    

Frequent Contributor
Posts: 118

Re: Can i filter and sort for 2 variables?

Posted in reply to AgSeedsBrett

Hi,

which type of output you need,, do you have sample output...? or looking for more explanation as your question is not clear....

Thanks

Uma Shanker Saini

New Contributor
Posts: 4

Re: Can i filter and sort for 2 variables?

Posted in reply to umashankersaini

I would like to create a new data table with the filtered information in order to run ANOVA tests for significant differences. Attached is an example of a file i will be using.  I would llike to be able to choose 2 or more "varieties" and filter out where those selected varieties appear in the same "trial #"

Attachment
Contributor
Posts: 29

Re: Can i filter and sort for 2 variables?

Posted in reply to AgSeedsBrett

*If I understood it as right then please try where option to filter;

data want;

set have;

where location in (2,3);

run;

Ask a Question
Discussion stats
  • 3 replies
  • 165 views
  • 0 likes
  • 3 in conversation