Skip to main content
Statistics LibreTexts

2.8: Using SPSS

  • Page ID
    49996

    \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)

    ( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\id}{\mathrm{id}}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\kernel}{\mathrm{null}\,}\)

    \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\)

    \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\)

    \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    \( \newcommand{\vectorA}[1]{\vec{#1}}      % arrow\)

    \( \newcommand{\vectorAt}[1]{\vec{\text{#1}}}      % arrow\)

    \( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vectorC}[1]{\textbf{#1}} \)

    \( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

    \( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

    \( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

    \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)

    Software can be used to expedite analyses and aid in the creation of tables and graphs. One that is commonly used by behavioral and social scientists and statisticians is called SPSS (which is owned by IBM). SPSS stands for Statistical Package for Social Sciences. This software can be used to quickly organize, summarize, and analyze data once data have been properly entered into the program.

    Entering Data

    Start by identifying how many variables you have and whether data for each are represented with numbers or letters. Then, identify whether each was measured on the nominal, ordinal, interval, or ratio scale.

    Next, open the SPSS software. Click “New Dataset,” then click “Open.” In some versions of SPSS the word “Open” is replaced with “OK.” This will create a new blank spreadsheet into which you can enter data. There are two tabs which appear towards the bottom of the spreadsheet. One is called “Variable View” which is the tab that allows you to tell the software about your variables. The other is called “Data View” which is the tab that allows you to enter your data.

    Click on the Variable View tab. This tab of the spreadsheet has several columns to organize information about the variables. The first column is titled “Name.” Start here and follow these steps:

    1. Click the first cell of the “Name” column and enter the name of your first variables using no spaces, special characters, or symbols. Hit enter and SPSS will automatically fill in the other cells of that row with some default assumptions about the data.
    2. Click the first cell of the column titled “Type” and then click the three dots that appear in the right side of the cell. Specify whether the data for that variable appear as numbers by selecting “Numeric” or as letters or words by selecting “String.” There are other options for specific kinds of data such as dates and currency which can be selected as appropriate for the data. Then click “OK.” For numeric data SPSS will automatically allow you to enter values that are up to 8 digits in length with decimals shown to the hundreds place as noted in the “Width” and “Decimal” column headers, respectively. You can edit these as needed to fit your data, though these settings will be appropriate for most quantitative variables in the behavioral sciences.
    3. Click the first cell of the column titled “Label.” This is where you can specify what you want the variable to be called in output, including in tables and graphs. You can use spaces or phrases here.
    4. Click on the first cell of the column titled “Measure.” A pulldown menu with three options will allow you to specify the scale of measurement for the variable. However, SPSS does not differentiate between interval and ratio and, instead, refers to both of these as “Scale.” Select the option that best fits the data for your variable.
    5. Move to the second row of the spreadsheet, starting with the cell under “Name” and repeat steps 1-4 until you have entered the information for all of your variables.

    Here is what the Variable View tab would look like when created for Data Set 2.1:

    undefined

    Notice that the type specified for Annual Salary is numeric. This does not change how the data can be used but if you prefer to view these data with dollar symbols, you can change the type specified for this variable to “Dollar.”

    Now you are ready to enter your data. Click on the Data View tab toward the bottom of the spreadsheet. This tab of the spreadsheet has several columns into which you can enter the data for each variable. Each column will show the names given to the variables that were entered previously using the Variable View tab. Click the first cell corresponding to the first row of the first column. Start here and follow these steps:

    1. Enter the data for the first variable moving down the rows under the first column. If your data are already on your computer in a spreadsheet format such as excel, you can copy-paste the data in for the variable. Note: If the spreadsheet will not allow you to enter the information and/or makes a blunt tone when you try to enter the data, it means you have an error in the format of the data you are trying to enter or that they do not match the details you provided in the Variable View tab. Change the data format or go back to edit the information on the Variable View tab if this occurs, as appropriate. Then, return to the Data View tab to enter your data.
    2. Repeat step 1 for each variable until all of your data have been entered.
    3. Then hit save to ensure your data set will be available for you in the future.
    Note

    Data entered into SPSS are saved in a file format that can only be opened in specific forms of software such as SPSS. Therefore, if you use a computer at school or work that has SPSS to make data files and try to open them on a different computer which does not have SPSS, you will not be able to. Keep this in mind if you plan to use different devices while practicing the use of SPSS and statistics.

    Here is what the Data View tab would look like when created for Data Set 2.1:

    undefined

    Once all the variables have been specified and the data have been entered, you can begin analyzing the data using SPSS.

    Generating Histograms

    The steps to generating a histogram in SPSS are:

    1. Click Graphs -> Histogram.
      1. In some versions of SPSS the histogram option is a bit more hidden. If you are using a version where it does not appear in the initial graphs option menu, use these steps to generate a histogram in SPSS: Click Graphs -> Legacy Dialogs -> Histogram.
    2. Drag the name of the variable you want to plot as a histogram from the variable list on the left into the Variable text box on the right of the command window. You can also do this by clicking on the variable name to highlight it and the clicking the arrow to move the variable from the left into the Variable text box on the right.
    3. Click OK.
    4. The histogram will appear in the SPSS output viewer but may not look the way you want it to.

    To edit your histogram, follow these additional steps:

    1. Double-click the histogram to open the chart editor.
    2. Double-click on any anchor under the x-axis to begin editing the presentation of scores or intervals along this axis.
      1. Click “Scale” if you want to adjust the range shown and the size of intervals. Enter the values you wish to use in the “Custom” text boxes. Click on “Number Format” if you want to change how many decimal places are shown for values along the x-axis. Fill in the text boxes to indicate the desired number of decimals to show. Click “apply” to see the graph adjusted to your specifications. Repeat these steps until you are satisfied with the organization of the x-axis.
    3. Double-click on any number along the y-axis to begin editing the specificity of frequencies. a) “Click “Scale” if you want to adjust the specificity of frequencies shown along the y-axis. Enter the values you wish to use in the “Custom” text boxes. Click on “Number Format” if you want to change how many decimal places are shown for values along the y-axis. This is rarely needed as the default is to show to the whole number which is appropriate for most data. When whole numbers are not desired, fill in the text boxes to indicate the desired number of decimals to show. Click “apply” to see the graph adjusted to your specifications. Repeat these steps until you are satisfied with the organization of the y axis.
    4. Double-click on any bar of the histogram to begin editing the appearance of the bars. a) Click “Fill & Border” if you would like to change the colors of the bars or their borders. Select the desired colors. You can also change the style and width of the borders here. To change the thickness of the borders, use the pulldown window under “Weight.” To Change the style of the bar borders, use the pulldown window under “Style.” Click “apply” to see the graph adjusted to your specifications. Repeat these steps until you are satisfied with the appearance of the bars of the histogram.

    Generating Simple Bar Graphs

    The steps to generating a univariate bar graph in SPSS are:

    1. Click Graphs -> Bar Graph -> Simple -> Define
    2. Drag the name of the variable you want to plot as a bar graph from the left into the Category Axis text box on the right of the command window. You can also do this by clicking on the variable name to highlight it and the clicking the arrow to move the variable from the left into the Category Axis text box on the right.
    3. Click OK.
    4. The bar graph will appear in the SPSS output viewer but may not look the way you want it to.

    To edit your bar graph, follow these additional steps:

    1. Double-click the bar graph to open the chart editor.
    2. Double-click on any anchor under the x-axis to begin editing the presentation of categories shown along this axis.
      1. Click “Categories” if you want to adjust the order of the categories shown. Each category will be listed under “Order.” Drag the names of the categories into their desired order. You may also want to change the angle at which the category names appear under the x-axis. To change this, click on “Labels & Ticks.” Then select the preferred orientation from the pull-down menu under “Label orientation.” This is where you can choose whether you want the names to appear vertically, horizontally, or at an angle under the x-axis. Click “apply” to see the graph adjusted to your specifications. Repeat these steps until you are satisfied with the organization of the x-axis.
    3. Double-click on any number along the y-axis to begin editing the specificity of frequencies.
      1. Click “Scale” if you want to adjust the specificity of frequencies shown along the y-axis. Enter the values you wish to use in the “Custom” text boxes. Click on “Number Format” if you want to change how many decimal places are shown for values along the y-axis. This is rarely needed as the default is to show to the whole number which is appropriate for most data. When whole numbers are not desired, fill in the text boxes to indicate the desired number of decimals to show. Click “apply” to see the graph adjusted to your specifications. Repeat these steps until you are satisfied with the organization of the y axis.
      2. If you would like the y-axis to be labeled as “frequency” instead of “count.” Double-click on the word “count” where it appears beside the y-axis. This will activate the textbox for the y-axis label so that you can edit it. Click outside of this label textbox when you are satisfied with the name you have given to the y-axis.
    4. Double-click on any bar of the histogram to begin editing the appearance of the bars.
      1. Click “Fill & Border” if you would like to change the colors of the bars or their borders. Select the desired colors. You can also change the style and width of the borders here. To change the thickness of the borders, use the pulldown window under “Weight.” To Change the style of the bar borders, use the pulldown window under “Style.” If you want to change the width of the gaps between bars, click “Bar Options.” Use the slide ruler under “Bars” to indicate the desired gap width. Click “apply” to see the graph adjusted to your specifications. Repeat these steps until you are satisfied with the appearance of the bars of the histogram.

    This page titled 2.8: Using SPSS is shared under a CC BY-NC-SA 4.0 license and was authored, remixed, and/or curated by .

    • Was this article helpful?