New Feature: Playlist Center! Pick a topic and let our playlists guide the way.

Start learning with our library of video tutorials taught by experts. Get started

SPSS Statistics Essential Training (2011)
Illustration by

Recoding variables


From:

SPSS Statistics Essential Training (2011)

with Barton Poulson

Video: Recoding variables

Many times your data won't come in exactly the form that you need it for analysis. For example, you may have groups that need to be combined, or you may have outcomes that need to be counted or scores that need to be reversed to be more interpretable in your results. All of these fall in the general rubric of recoding variables. There are several ways to do this in SPSS. The first way that I want to show you in particular movie is what you might call a manual recode. And the way you do this is by coming up to the Transform menu and then you select either Recode into Same Variable or Recode into Different Variables.
Expand all | Collapse all
  1. 2m 58s
    1. Welcome
      1m 5s
    2. Using the exercise files
      40s
    3. Using a different version of the software
      1m 13s
  2. 19m 0s
    1. Taking a first look at the interface
      11m 49s
    2. Reading data from a spreadsheet
      7m 11s
  3. 21m 54s
    1. Creating bar charts for categorical variables
      7m 18s
    2. Creating pie charts for categorical variables
      2m 54s
    3. Creating histograms for quantitative variables
      5m 45s
    4. Creating box plots for quantitative variables
      5m 57s
  4. 33m 10s
    1. Recoding variables
      5m 33s
    2. Recoding with visual binning
      5m 33s
    3. Recoding by ranking cases
      5m 26s
    4. Computing new variables
      5m 37s
    5. Combining or excluding outliers
      5m 21s
    6. Transforming outliers
      5m 40s
  5. 28m 12s
    1. Selecting cases
      6m 44s
    2. Using the Split File command
      5m 12s
    3. Merging files
      5m 33s
    4. Using the Multiple Response command
      10m 43s
  6. 22m 14s
    1. Calculating frequencies
      8m 43s
    2. Calculating descriptives
      5m 31s
    3. Using the Explore command
      8m 0s
  7. 16m 3s
    1. Calculating inferential statistics for a single proportion
      6m 6s
    2. Calculating inferential statistics for a single mean
      5m 39s
    3. Calculating inferential statistics for a single categorical variable
      4m 18s
  8. 30m 43s
    1. Creating clustered bar charts
      7m 10s
    2. Creating scatterplots
      5m 8s
    3. Creating time series
      3m 24s
    4. Creating simple bar charts of group means
      4m 17s
    5. Creating population pyramids
      3m 0s
    6. Creating simple boxplots for groups
      3m 3s
    7. Creating side-by-side boxplots
      4m 41s
  9. 45m 28s
    1. Calculating correlations
      8m 17s
    2. Computing a bivariate regression
      6m 27s
    3. Creating crosstabs for categorical variables
      6m 34s
    4. Comparing means with the Means procedure
      6m 33s
    5. Comparing means with the t-test
      6m 4s
    6. Comparing means with a one-way ANOVA
      6m 30s
    7. Comparing paired means
      5m 3s
  10. 24m 30s
    1. Creating clustered bar charts for frequencies
      6m 34s
    2. Creating clustered bar charts for means
      3m 45s
    3. Creating scatterplots by group
      4m 13s
    4. Creating 3-D scatterplots
      4m 25s
    5. Creating scatterplot matrices
      5m 33s
  11. 30m 57s
    1. Using Automatic Linear Models
      11m 52s
    2. Calculating multiple regression
      9m 3s
    3. Comparing means with a two-factor ANOVA
      10m 2s
  12. 29m 29s
    1. Formatting descriptive statistics
      6m 1s
    2. Formatting correlations
      7m 49s
    3. Formatting regression
      10m 19s
    4. Exporting charts and tables
      5m 20s
  13. 51s
    1. What's next
      51s

Watch this entire course now—plus get access to every course in the library. Each course includes high-quality videos taught by expert instructors.

Become a member
please wait ...
SPSS Statistics Essential Training (2011)
5h 5m Beginner Aug 17, 2011

Viewers: in countries Watching now:

In this course, author Barton Poulson takes a practical, visual, and non-mathematical approach to the basics of statistical concepts and data analysis in SPSS, the statistical package for business, government, research, and academic organization. From importing spreadsheets to creating regression models to exporting presentation graphics, this course covers all the basics, with an emphasis on clarity, interpretation, communicability, and application.

Topics include:
  • Importing and entering data
  • Creating descriptive charts
  • Modifying and selecting cases
  • Calculating descriptive and inferential statistics
  • Modeling associations with correlations, contingency tables, and multiple regression
  • Formatting and exporting tables and charts
Subjects:
Business Data Analysis
Software:
SPSS
Author:
Barton Poulson

Recoding variables

Many times your data won't come in exactly the form that you need it for analysis. For example, you may have groups that need to be combined, or you may have outcomes that need to be counted or scores that need to be reversed to be more interpretable in your results. All of these fall in the general rubric of recoding variables. There are several ways to do this in SPSS. The first way that I want to show you in particular movie is what you might call a manual recode. And the way you do this is by coming up to the Transform menu and then you select either Recode into Same Variable or Recode into Different Variables.

Now let me give you a quick warning here, when you recode into the same variable you're overwriting existing data, and while that maybe able to save some space, if you make a mistake in the recode, you will not be able to go back to what you had before. And for that reason, I recommend that you almost always recode into a different variable, which is what I am going to do in this particular case. By the way, the one I'm going to look at is this one here at the end. It's called In the Past 30 Days Have You Felt Worthless? and there are several responses that go from Never to Almost Every Day and what I am going to do in this particular one is I am going to recode it as people who have never versus at least sometimes.

So I am going to be taking all of the answers above zero and making them into a single Yes code, that they have felt worthless at at least some point in the past few weeks. So what I do is I start by taking this variable. It's called Numeric Variable and it's FeelWorthless, and I am going to create-- and I call it, EverFeltWorthless because the other one asked about how often. This one is going to be "Have you ever?" and I am going to be put in the label for this one and I am going to call it Has EverFeltWorthless. And I click Change and now it puts FeelWorthless would be coded into EverFeltWorthless.

Then what I need to do is I need to specify the old and the new values for the recode. Well, what I am going to do in this one is I am going to take zero, and that's going to stay zero, so those are the people who said they never felt worthless-- that's going to stay that way--but then what I am going to do is I am going to specify a range, and I am going to put anything 1 through the highest value, so that's 2s, 3s and 4s, that that any of those can become a 1. Now this new one I am creating is going to be called an Indicator Variable.

That's a 0/1, yes/no variable. It's a good way to do it because it allows you to also do certain numerical statistical procedures with it. Now if I wanted to set up a more detailed correspondence, I could. Say for instance, I had a variable in an opinion survey that was coded as 1 strongly disagree, up to 5 strongly agree, but then it was reverse-coded so that, for instance, in this particular case, people are talking about what they did not like. In order to make things consistent, I may need to switch it around, and I may need to switch 1 to 5, 2 to 4, 3 stays the same, 4 to 2, and 5 to 1.

I can do that by putting in each one of these manually, but because I have a pattern here where I am putting 0 stays 0 and everything else goes to a 1, I can do this particular method. 0 stays a 0, but everything else goes to a 1. Now that that's done, I can press OK and this is the syntax statement. The command is RECODE. It says Worthless (0=0) 1, so everything else equals to 1, into the new variable and then it has a label for the variable. The long name of it is EverFeltWorthless and then I turn that into a sentence, or phrase, for the label. And then the EXECUTE means it actually did the command.

Now, you don't see anything else here because this doesn't produce a graph. It adds a column. It adds a variable to the data label. So if we go back to the data set and I go to the end, now you'll see a new variable here called EverFeltWorthless, and it's made out of 0s and 1s. Now I need to do a couple of things to clean this up here. Number one is it's got these decimal places that I don't need, because I don't have any 1.5s, I just have 1s and 0s. So I am going to come down to Variable view and I am going to change that 1 to have 0 decimal places.

Also, I want to indicate that the 0 means no and 1 means yes, so I am going to come over to Values, click on that, click on the little box here, and I am going to type in value. I am going to put in a 0 and say that that means no. Click Add, and then I come back up to 1, and the Label is Yes. When I click OK, and that adds the labels. Now I go back here. I can see those on here now. So what I have done is I've taken an existing variable and if I click back here on the Value Labels button, you can see that I had 0s and 4s and so on that have all become 0s and 1s.

So I've gone from something that had a very small number of people on the high end to trying to create groups that were slightly larger for working with by people who said they ever felt worthless. This by that way is from the general social survey. It's national survey of people across the country of all age ranges. And this is one way to save this coding to get a variable that's more useful in particular analyses. Now in the next couple of videos I am going to show you how to use something called visual binning and then something called ranking, and those are two other methods of taking the information that you have and putting it into a system that would work better for the analyses that you are going to do.

There are currently no FAQs about SPSS Statistics Essential Training (2011).

 
Share a link to this course

What are exercise files?

Exercise files are the same files the author uses in the course. Save time by downloading the author's files instead of setting up your own files, and learn by following along with the instructor.

Can I take this course without the exercise files?

Yes! If you decide you would like the exercise files later, you can upgrade to a premium account any time.

Become a member Download sample files See plans and pricing

Please wait... please wait ...
Upgrade to get access to exercise files.

Exercise files video

How to use exercise files.

Learn by watching, listening, and doing, Exercise files are the same files the author uses in the course, so you can download them and follow along Premium memberships include access to all exercise files in the library.
Upgrade now


Exercise files

Exercise files video

How to use exercise files.

For additional information on downloading and using exercise files, watch our instructional video or read the instructions in the FAQ.

This course includes free exercise files, so you can practice while you watch the course. To access all the exercise files in our library, become a Premium Member.

join now Upgrade now

Are you sure you want to mark all the videos in this course as unwatched?

This will not affect your course history, your reports, or your certificates of completion for this course.


Mark all as unwatched Cancel

Congratulations

You have completed SPSS Statistics Essential Training (2011).

Return to your organization's learning portal to continue training, or close this page.


OK
Become a member to add this course to a playlist

Join today and get unlimited access to the entire library of video courses—and create as many playlists as you like.

Get started

Already a member?

Become a member to like this course.

Join today and get unlimited access to the entire library of video courses.

Get started

Already a member?

Exercise files

Learn by watching, listening, and doing! Exercise files are the same files the author uses in the course, so you can download them and follow along. Exercise files are available with all Premium memberships. Learn more

Get started

Already a Premium member?

Exercise files video

How to use exercise files.

Ask a question

Thanks for contacting us.
You’ll hear from our Customer Service team within 24 hours.

Please enter the text shown below:

The classic layout automatically defaults to the latest Flash Player.

To choose a different player, hold the cursor over your name at the top right of any lynda.com page and choose Site preferencesfrom the dropdown menu.

Continue to classic layout Stay on new layout
Exercise files

Access exercise files from a button right under the course name.

Mark videos as unwatched

Remove icons showing you already watched videos if you want to start over.

Control your viewing experience

Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.

Interactive transcripts

Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.

Are you sure you want to delete this note?

No

Notes cannot be added for locked videos.

Thanks for signing up.

We’ll send you a confirmation email shortly.


Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

Keep up with news, tips, and latest courses with emails from lynda.com.

Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

   
submit Lightbox submit clicked
Terms and conditions of use

We've updated our terms and conditions (now called terms of service).Go
Review and accept our updated terms of service.