Mikelowski
Mikelowski

Reputation: 195

Selecting cut-off scores for different group ages in SPSS

I have 2 variables: age and score. I want to select cases among ages 0 to 64 who scored 4 or more, and select also cases among ages 65 to 80 who scored 6 or more. So, basically a filter keeping all those cases.

How can I do this with syntax?

Thanks ;)

Upvotes: 2

Views: 3139

Answers (1)

Andy W
Andy W

Reputation: 5089

DO IF (Age <= 64 AND Score >= 4).
  COMPUTE Filter = 1.
ELSE IF (Age >= 65 AND Age <= 80 AND Score >= 6).
  COMPUTE Filter = 2.
ELSE.
  COMPUTE Filter = 0.
END IF.
SELECT IF Filter > 0.

Upvotes: 1

Related Questions