GAP%20Toolkit%205%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20Training%20in%20basic%20drug%20abuse%20data%20management%20and%20analysis - PowerPoint PPT Presentation

About This Presentation
Title:

GAP%20Toolkit%205%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20Training%20in%20basic%20drug%20abuse%20data%20management%20and%20analysis

Description:

GAP Toolkit 5 Training in basic drug abuse data management and analysis – PowerPoint PPT presentation

Number of Views:24
Avg rating:3.0/5.0
Slides: 35
Provided by: test323
Learn more at: https://www.unodc.org
Category:

less

Transcript and Presenter's Notes

Title: GAP%20Toolkit%205%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20Training%20in%20basic%20drug%20abuse%20data%20management%20and%20analysis


1
GAP Toolkit 5
Training in basic drug abuse data
management and analysis
Training session 7 SPSS Recode and Compute
2
Objectives
  • To introduce and demonstrate SPSS tools for
    recoding variables and creating new variables
  • To introduce and demonstrate the use of SPSS
    command syntax
  • To introduce and demonstrate Help features in
    SPSS from a dialogue box

3
Types of recode
  • A categorical variable into a new set of
    categories
  • A continuous variable into a categorical variable

4
Recode approaches
  • Into pre-defined categories of interest
  • Into categories of equal size

5
Example pre-defined categories
  • Recode weekly expenditure on drugs into the
    following categories
  • Low expenditure lt 100 a week
  • High expenditure gt 101 a week

6
(No Transcript)
7
select variable for recoding and click
8
(No Transcript)
9
click here to map old ? new values
10
(No Transcript)
11
(No Transcript)
12
Weekly drug expenditure
Frequency Percent Valid percent Cumulative percent
Valid Low 31 62.0 62.0 62.0
High 19 38.0 38.0 100.0
Total 50 100.0 100.0
13
Example quantiles
  • Recode weekly expenditure into the following
  • 4 categories, each with approximately the same
    number of cases (quartiles)
  • 10 categories, each with approximately the same
    number of cases (deciles)

14
(No Transcript)
15
NTILES of Expend
Frequency Percent Valid percent Cumulative percent
Valid lt90 12 24.0 24.0 24.0
91 lt X lt 98 12 24.0 24.0 48.0
99 lt X lt 105 13 26.0 26.0 74.0
106 lt X gt 116 13 26.0 26.0 100.0
Total 50 100.0 100.0
16
NTILES of EXPEND
Frequency Percentage Valid percentage Cumulative percentage
Valid 1 5 10.0 10.0 10.0
2 4 8.0 8.0 18.0
3 7 14.0 14.0 32.0
4 4 8.0 8.0 40.0
5 4 8.0 8.0 48.0
6 6 12.0 12.0 60.0
7 5 10.0 10.0 70.0
8 5 10.0 10.0 80.0
9 6 12.0 12.0 92.0
10 4 8.0 8.0 100.0
Total 50 100.0 100.0
17
Compute
  • Creates new variables using
  • Standard mathematical operators
  • A full range of functions
  • Conditional statements

18
Transform/Compute
click here to define variable type
19
Type and Label
20
YexpendExpend52
21
Explore Yexpend
Descriptives
Statistic Std. error
Yearly drug expenditure Mean 5062.72 77.468
95 Confidence Interval for Mean Lower Bound 4907.04
Upper Bound 5218.40
5 Trimmed Mean 5072.89
Median 5148.00
Variance 300062.3
Std. Deviation 547.779
Minimum 3848
Maximum 6032
Range 2184
Interquartile Range 754.00
Skewness -.333 .337
Kurtosis -.446 .662
22
Example 2 Age
  • Convert date of birth to age in years

23
(DATE.DMY(01,01,2002) - dob) / (365.25246060)
24
Explore Age
Descriptives
Statistic Std. error
AGE Mean 25.43 1.219
95 Confidence Interval for Mean Lower Bound 22.97
Upper Bound 27.88
5 Trimmed Mean 25.21
Median 22.84
Variance 72.867
Std. Deviation 8.536
Minimum 11
Maximum 44
Range 32
Interquartile Range 12.77
Skewness .579 .340
Kurtosis -.518 .668
25
Help
  • Context-sensitive Help
  • Right click on any part of a dialogue box to
    obtain help
  • Dialogue box Help button

26
(No Transcript)
27
(No Transcript)
28
Command language
  • Command-line rather than Windows interface
  • More flexible
  • Reusable
  • Saved as text files

29
Syntax window
  • Enter SPSS commands
  • Type directly
  • Paste from a dialogue box
  • Run SPSS commands
  • Save as a text file

30
The Paste button
click to copy command into Syntax Window
31
(No Transcript)
32
The Run menu
33
Syntax for Age
34
Summary
  • Recode
  • Into same variable
  • Into different variable
  • Compute
  • Mathematical operators
  • Functions
  • Dialogue box Help
  • Context-sensitive Help
  • Dialogue box Help button
  • Command language
  • Syntax Window
  • Dialogue box Paste button
Write a Comment
User Comments (0)
About PowerShow.com