• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
The Analysis Factor

The Analysis Factor

Statistical Consulting, Resources, and Statistics Workshops for Researchers

  • Home
  • About
    • Our Programs
    • Our Team
    • Our Core Values
    • Our Privacy Policy
    • Employment
    • Guest Instructors
  • Membership
    • Statistically Speaking Membership Program
    • Login
  • Workshops
    • Online Workshops
    • Login
  • Consulting
    • Statistical Consulting Services
    • Login
  • Free Webinars
  • Contact
  • Login

An Easy Way to Reverse Code Scale items

by Karen Grace-Martin 27 Comments

Before you run a Cronbach’s alpha or factor analysis on scale items, it’s generally a good idea to reverse code items that are negatively worded so that a high value indicates the same type of response on every item.

So for example let’s say you have 20 items each on a 1 to 7 scale. For most items, a 7 may indicate a positive attitude toward some issue, but for a few items, a 1 indicates a positive attitude.

I want to show you a very quick and easy way to reverse code them using a single command line. This works in any software.

Rather than specifying each individual recoded value–a 1 to 7, 2 to 6, and so on, just subtract the values from a constant one value higher than the highest value on the scale.

For example if OldVariable is reverse coded and on a 1 to 7 scale, in SPSS, do this:

COMPUTE NewVariable = 8 – OldVariable.  (You can also do it in the menus in Transform–>Compute).

In SAS, do this within a data step.

Data scale;
Set scale;
NewVariable = 8 – OldVariable;
Run;

The value from which you subtract your old variable will always be one value higher than the highest value you have. So I subtracted my old variable from 8 because I have a 1 to 7 scale. If I had a 1 to 5 scale, I would subtract my old variable from 6.

You can see how it works:

8-7=1
8-6=2
8-5=3
8-4=4
8-3=5
8-2=6
8-1=7

If you only have to reverse code one item, this isn’t a big deal.  But I have found that data cleaning and creating new variables often is the step in data analysis that takes the longest. I use whatever shortcuts I can.

Principal Component Analysis
Summarize common variation in many variables... into just a few. Learn the 5 steps to conduct a Principal Component Analysis and the ways it differs from Factor Analysis.

Tagged With: recode, reverse coding, SAS, SPSS

Related Posts

  • Statistical Software Access From Home
  • Member Training: What’s the Best Statistical Package for You?
  • Tricks for Using Word to Make Statistical Syntax Easier
  • Ten Ways Learning a Statistical Software Package is Like Learning a New Language

Reader Interactions

Comments

  1. Olagunju Nasiru says

    November 25, 2020 at 2:08 pm

    Very useful, I needed to do this to some NDVI values but I neither knew how to do nor even know the name it’s called. Some random google search landed me here and it’s a solution to my quest.

    Thanks so much.

    Reply
  2. cmg says

    June 1, 2018 at 2:32 pm

    Just a quick thanks from a survey researcher who was given a hard copy table set and that’s all. I was not a part of the design, and they had a ranked mean reversed. When will people learn that it takes a professional to design a survey!?!

    Reply
  3. Dan Kuchinka says

    November 8, 2017 at 7:40 pm

    Duh….lol…I was subtracting from 7. Thank you Dr. Karen. Once I got help from you I realized who you were by seeing the book add under “Read Our Book”…I have it right next to me as I am writing this.

    Great book when I was a student.

    Reply
  4. Masoud Khamallag says

    October 23, 2017 at 6:58 pm

    Alpha still negative !!!!/ even after reversing the negative wording, the sample is 900, the question is multiple responses (includes 5 sub-questions) wither it is selected or not. what to do? please ?

    Reply
  5. Student says

    May 29, 2017 at 12:53 am

    How to reverse coding continuous variables?
    Thanks

    Reply
  6. SAGAR says

    February 7, 2017 at 2:21 pm

    My questions in negative form like how often you faced problem from dampness? Scale i used 1 never and 6 very often.. So most of answer came near 2 or 3… Then can i use reverse coding?

    Reply
  7. Anna says

    January 5, 2017 at 12:11 am

    If appears a negative factor loading in second order exploratory factor analysis, what I do? Can I reverse de coding of that first order factor? If yes, how I do that?

    My main goal is to calculate the internal consistency of a second order factor, but on of the loadings gave a negative value…

    Reply
  8. thush says

    December 20, 2016 at 4:04 am

    how I categorical in 5 likert scale in this frequencies. 1 strongly agree
    2 Agree 3 Neither agree or disagree 4 Disagree 5 Strongly disagree

    Valid 2.00
    3.00
    4.00
    5.00
    Total 120

    Reply
  9. MAL says

    August 3, 2016 at 10:19 am

    I’m doing a pre-post test for students in a class using different methods for half the class sessions – same students. I want to compare which collection methods are received or appreciated the most. How can I use a paired t-test for this comparison?

    MAL

    Reply
  10. diana says

    October 6, 2015 at 2:26 pm

    Thanks! That saved me a lot of time.

    Reply
  11. Tan says

    April 26, 2015 at 4:41 am

    Hello.. can you teach me how to compute data which got question in Likert scale? how to compute the score to the answer as 1 = "Strongly disagree" , 2 = "Disagree", 3 = "Agree", 4 = "Strongly Agree"Thank You.

    Reply
  12. ftreu says

    March 26, 2015 at 2:20 pm

    The way you propose is the quickest ro reverse the direction of an item. I use it often.

    If you have missing values you have to complete the action with a new assignment for missing values.

    Reply
    • Karen says

      March 31, 2015 at 4:11 pm

      Good point. You’re creating a new variable so it does need new missing value assignments.

      Reply
  13. Cynthia says

    March 10, 2015 at 9:25 am

    Hello,

    Agreed data cleaning is very challenging. So my colleague and I have followed the steps to reverse code into a different and new variable, then when we computed the recoded variables and other unchanged variables our output seemed wrong. Are there any additional steps we may have missed, I have made efforts to do research, but I am wondering if I am not using the correct language when research. Any guidance would help tremendously.

    Thank you,
    Cynthia

    Reply
    • Addie says

      July 29, 2019 at 1:54 pm

      Did you use brackets if you were doing a bunch of items at once? Man, it pains me to go back…

      Reply
  14. Derek says

    August 6, 2014 at 9:21 am

    Cool! Thank you very much!

    Reply
  15. Ruth says

    August 3, 2014 at 3:37 pm

    Hello –
    How do I label items on a sub-scale that were first (1) reversed scored by recoding into a different variable, (2) then were averaged (Transform > Compute, etc)? Do I use the label from the reversed scored items, or the labels from the not-reversed scored items? For example, of my 10 items on the IPIP 50-item scale, for “Extroversion” 5 items were reversed scored. When I get the MEAN of those items, in the Variable view, under “Label”, how do I label that new scale on a scale of 1 – 5? Thanks so much for your help!
    Ruth

    Reply
  16. student says

    March 24, 2014 at 11:53 am

    this might work, if your intention is: high number on a scale is a good thing. but if your scale is supposed to measure sexist attitudes, you better inverse the positive worded items.

    this equals a low mean value on the whole scale, indicating that those low on the scale are not sexist, those high are!

    Reply
    • Karen says

      April 4, 2014 at 12:56 pm

      Well, yes, that’s the whole point of recoding the direction of the scale.

      Reply
  17. Lise says

    November 8, 2013 at 3:29 am

    What if my categories have names like “agree” “somewhat agree” “somewhat disagree” and “disagree”? How do I keep the names without transforming the categories into number?

    Reply
    • Karen says

      November 8, 2013 at 11:32 am

      Hi Lise,

      You can still recode them, but you’ll have to do it the long way. Recode each old value into a new value.

      Reply
  18. Roze says

    July 24, 2013 at 9:49 pm

    Thank you sooo much! So simple.

    Reply
  19. Sheng says

    April 16, 2013 at 5:19 pm

    This saved me a bunch of time! Thanks!

    Reply
    • Karen says

      April 19, 2013 at 2:40 pm

      Awesome. 🙂

      Reply
  20. Ryan says

    July 2, 2012 at 2:49 pm

    So clever. Thanks!

    Reply
  21. Jake says

    June 29, 2012 at 3:33 pm

    The method you have presented works well when the lowest possible scale value is 1. The more general method for reverse scoring would be:
    reversed score = (minimum score) + (maximum score) – actual score

    Reply
    • Karen says

      June 29, 2012 at 6:42 pm

      Ah, yes! Excellent.

      Karen

      Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Please note that, due to the large number of comments submitted, any questions on problems related to a personal study/project will not be answered. We suggest joining Statistically Speaking, where you have access to a private forum and more resources 24/7.

Primary Sidebar

This Month’s Statistically Speaking Live Training

  • January Member Training: A Gentle Introduction To Random Slopes In Multilevel Models

Upcoming Workshops

  • Logistic Regression for Binary, Ordinal, and Multinomial Outcomes (May 2021)
  • Introduction to Generalized Linear Mixed Models (May 2021)

Read Our Book



Data Analysis with SPSS
(4th Edition)

by Stephen Sweet and
Karen Grace-Martin

Statistical Resources by Topic

  • Fundamental Statistics
  • Effect Size Statistics, Power, and Sample Size Calculations
  • Analysis of Variance and Covariance
  • Linear Regression
  • Complex Surveys & Sampling
  • Count Regression Models
  • Logistic Regression
  • Missing Data
  • Mixed and Multilevel Models
  • Principal Component Analysis and Factor Analysis
  • Structural Equation Modeling
  • Survival Analysis and Event History Analysis
  • Data Analysis Practice and Skills
  • R
  • SPSS
  • Stata

Copyright © 2008–2021 The Analysis Factor, LLC. All rights reserved.
877-272-8096   Contact Us

The Analysis Factor uses cookies to ensure that we give you the best experience of our website. If you continue we assume that you consent to receive cookies on all websites from The Analysis Factor.
Continue Privacy Policy
Privacy & Cookies Policy

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary
Always Enabled

Necessary cookies are absolutely essential for the website to function properly. This category only includes cookies that ensures basic functionalities and security features of the website. These cookies do not store any personal information.

Non-necessary

Any cookies that may not be particularly necessary for the website to function and is used specifically to collect user personal data via analytics, ads, other embedded contents are termed as non-necessary cookies. It is mandatory to procure user consent prior to running these cookies on your website.