DrMaxKeck
DrMaxKeck

Reputation: 31

Loop over years in SPSS Syntax

I have this code.

Select if (syear=1995 and Niedriglohn=1).
Frequencies NiedriglohnDauer.

I want to have the Frequencies of Niedriglohndauer for the year 1995 to 2020 each if Niedriglohn=1.

Upvotes: 2

Views: 27

Answers (1)

eli-k
eli-k

Reputation: 11360

This will do it:

Select if Niedriglohn=1.
sort cases by syear.
split file by syear.
Frequencies NiedriglohnDauer.
split file off.

Upvotes: 1

Related Questions