Docsity

Recoding in SPSS - Statistical Package for Social Sciences - Lecture Slides, Slides of Economic statistics

Partial preview of the text

Download Recoding in SPSS - Statistical Package for Social Sciences - Lecture Slides and more Slides Economic statistics in PDF only on Docsity!

Recoding in SPSS

Objectives

At the end of this session you will

• Be able to recode numerical variables

• Be able to recode string variables

automatically

• Be able to set system missing and user

defined missing values.

Example

Recode the variable age as follows:

• Values between 0 and 14 code as ‘children’

• Values between 15 and 55 code as ‘adult’

• Values over 55 code as ‘elderly’

Recoding into the same variable

1^ (menu)

2

3

4

Finally click on OK

Recoding into a different variable

  • Recoding into a different variable.

RECODE age

(Lowest thru 14 = 1) (15 thru 55 = 2) (56 thru Highest = 3)

into agecat.

Value labels agecat

1 “Child” 2 “Adult” 3 “Elderly”.

EXECUTE.

Spot the difference!

Autorecoding text variables

CROPPROD CROPPRO1 Did actively operate land for crop p

Old Value New Value Value Label na 1 na NA 2 NA No 3 No yes 4 yes Yes 5 Yes

This is what is needed to finish the

job!

recode croppro

(1 = 3)

(2 = 3)

(3 = 2)

(4 = 1)

(5 = 1).

variable labels croppro1 'Household actively operate land for crop production'.

value labels croppro

1 "Yes"

2 "No"

3 "N/A".