Unit 4 Working With Microsoft Excel and IBM SPSS Statistics Software SPSS
Unit 4 Working With Microsoft Excel and IBM SPSS Statistics Software SPSS
Unit 4 Working With Microsoft Excel and IBM SPSS Statistics Software SPSS
Launching Excel
• You can either double-click the Excel icon on your desktop, if available, or select
Microsoft Excel from the Start menu (Figure 4-1). Once you open Excel, the
opening screen should resemble Figure 4-2.
• Getting Started in Excel
• From the opening screen of Excel, you can create a new workbook or access your
recent workbooks. You will locate and select “Blank Workbook” to open a new
workbook, and click “Open Other Workbooks” to work on an existing workbook
(Figure 4-3).
Using Workbooks and Worksheets
• The workbook window provides the space for a variety of workbook elements,
such as the quick access toolbar and ribbon (Figure 4-4). There are many other
elements that an investigator can utilize to help with data analysis, but we will
discuss these as needed when we explain different types of statistical analyses.
Figure 4-1 Figure 4-2
Selecting
workbook in
Excel
Excel
workbook
elements
Figure 4-4
Basic Features of Microsoft Excel
• Excel provides numerous formulas and functions that allow you to quickly make
specific calculations. Although we cannot cover every formula and function, let us
learn how to perform basic calculations.
• For example, an emergency department (ED) nurse might be interested in how
many patient visits the ED had this past week. With the data shown in Figure 4-14,
click into cell B9 and type the equal (=) sign (Note: Formulas and functions always
begin with an equal sign), followed by “B2+B3+B4+B5+B6+B7+B8”, as we need to
add patients over the past 7 days. You should get “60” as a resulting value in cell B9
once you hit Enter (Figure 4-15).
• Note that you can also get the same value by clicking the “∑ Autosum” function on
the top right corner of the worksheet with cell B9 selected (Figure 4-16). A variety
of functions are available in the “Formulas” Tab, and clicking “Insert Functions” on
the top-left corner will open a new window, as shown in Figure 4-17.
Using Formula
and Functions
to Calculate
Values
Using Formula
and Functions
to Calculate
Values
Adding or Removing or Renaming Worksheets
• Additional worksheets can be added by clicking the new sheet button next to
“sheet1” (Figure 4-18), and multiple worksheets can be useful to organize a large
amount of data. You can rename a worksheet by doing the following:
• (1) double-click on the worksheet name to be renamed, or right-click on the
worksheet name to be renamed and choose “Rename” from the menu
• (2) type the desired name for the worksheet to be renamed
• (3) press Enter.
• To delete a worksheet, you will need to click on the worksheet to remove and
then choose Home➝Delete➝Delete Sheet on the Ribbon or right-click Tab and
then choose Delete from its shortcut menu.
Adding
Worksheet
SPSS: Major File Types in SPSS
• There are three major file types in SPSS: data files, syntax files, and output files.
• Data files (*.sav) contain the actual data values. Data can be either directly
entered into SPSS or be imported from other formats, such as Excel, dBase, and
Lotus files. Beginning with version 10.0, data files may be viewed from two
different windows, each with a separate purpose: data view and variable view.
Data view is where the data may be directly inputted, and variable view is where
the characteristics of the variables, such as variable name, type, label, and values,
are defined (Figure 4-21).
• Syntax files (*.sps). contain programmable SPSS commands to conduct analyses
(as shown in Figure 4-22) and are a good alternative to using the interactive
windows and drop-down menus. Although there are certain analyses that can only
be performed with syntax files, we will not discuss these in detail here, as most of
the analyses for our purposes can be conducted with interactive windows.
SPSS: Major File Types in SPSS
• Output files (*.spv) contain the results of the analyses, as well as any error
messages or warning messages (Figure 4-23). An output file can be saved, edited,
printed, or pasted into other applications such as Microsoft Word and PowerPoint.
Output file in
SPSS
Types of Drop-Down Menus
• Because SPSS uses interactive windows, it is a relatively user-friendly software
package. On SPSS 25.0, there are a total of 11 drop-down menus, which are
categorized into windows and general-purpose, data definition, and/or data analysis
drop-down menus.
• Windows and general-purpose menus include FILE, EDIT, VIEW, UTILITIES,
WINDOW, and HELP menus. The FILE and EDIT menus should be familiar, as these
are similar to other software packages.
• The FILE menu includes options to create new files, open existing files, or save and
print the files or outputs.
• The EDIT menu allows you to find a case or variable, to cut and paste a data value,
and so on.
• The HELP menu includes an SPSS tutorial, which we recommend, because it provides
detailed explanations on important topics and serves as a reference for users.
Types of Drop-Down Menus
• Data definition menus include the DATA and TRANSFORM menus.
• Data definition menus include the DATA and TRANSFORM menus. The DATA menu
includes procedures for inserting new variables or cases, sorting cases, merging
files, splitting the file, selecting cases, and weighting cases.
• The TRANSFORM menu includes procedures for recoding variables, replacing
missing values, computing new variables using existing variables, and a random
number generator. These two menus are useful when a researcher wants to
manipulate the file to resolve issues with violated assumptions or extremely
unequal sample sizes for different groups.
Types of Drop-Down Menus
• Data analysis menus include the ANALYZE and GRAPH menus.
• The ANALYZE menu includes both statistical and psychometric (reliability and
validity testing) procedures, and the GRAPH menu includes various procedures for
creating graphs and plots.
• One thing to note here is that some of these graph tools are available within
statistical procedures under the ANALYZE menu.
Entering Data into SPSS
Completing a Variable View
• When entering data into SPSS, the first step is to complete a variable view window.
This view displays the characteristics of the variables that must be defined so that
the data may be entered appropriately into data view. These characteristics include
variable name, type, width, decimals, label, values, missing, columns, align,
measure, and role. Only the commonly defined characteristics are covered here.
• The variable name should begin with a letter and only contain letters and
numbers. It should not contain punctuation or spaces and cannot begin with a
number. The name can be up to 64 characters in length, but we recommend using
short names, approximately 8 to 10 characters, as variable names longer than this
can create wordy outputs that may be difficult to read. For example, a question
such as, “How many times did you smoke during the past 3 months?” should be
named like “Smoke3” instead of using the entire question as a variable name.
Note: the name must not begin with a number and cannot contain special
characters such as @, $, space, and so on.
Entering Data into SPSS
• Type includes many different formats, but numeric and string are the most
commonly used ones. When the data are quantitative, such as age, the format
should be left as the default, numeric. The format should be changed to string
when the data are qualitative, such as responses to explain the choice of “other”
categories in racial groups.
• Decimal characterizes how many decimals are to be shown for variables. The
default is set to 2, or the hundredths place, but unless data will be recorded or
entered with decimals, we recommend changing to 0 to view the data more clearly.
• Label is a description of what a variable represents in more detail. Although we
recommend using a short variable name, it may be easy to forget what the
abbreviated variable name means. The label field allows up to 255 characters to
describe the nature of the variable in more detail. For example, if we are entering
data on wound characteristics, the variable name might be “depth,” but the label
may be much more detailed, such as “wound depth as measured in millimeters to
the nearest whole number.”
Entering Data into SPSS
• Values specify what numbers will be used to represent categories for categorical
variables. You will need to indicate how numbers are assigned for categories, and
this can be accomplished by clicking the gray square box with “...” on the right
corner of a cell. Consider a case in which we are recording race. We assign a
numerical value for each racial group: African American—1, Hispanic—2, Asian/
Pacific Islander—3, White —4, and Multiracial—5. Values allow us to assign a
number to categories of a discrete/categorical variable.
• Measures represent the level of measurement. Note that interval and ratio levels
of measurement are combined in the term Scale.
• Table 4-1 shows the characteristics that define each variable, and we recommend
spending some time using the drop-down menu to get the feel of it.
Characteristics to Define in Variable View
اﻟﺗﻌﺎرﯾف
Characteristics to Define in Variable View
Preparing a Codebook
• The next step of data entry is to prepare a codebook, which summarizes the
characteristics of the defined variables.
• The codebook guides the creation of the data file and helps minimize errors with
data entry. There are other components that may appear on the codebook, but a
typical codebook includes the following:
1. Variable labels
2. Variable name
3. Variable type (i.e., numeric or string)
4. Values for categories of categorical variables Values for missing data
• Go to Analyze > Report > Codebook to create a codebook, as shown in Figure 4-24.
The variable view of the sample data set is shown in Figure 4-25. Creating a
codebook as part of designing a study or evidence-based practice project is often
a useful exercise for exposing flaws in measurement decisions or prompting
questions about how data will be entered and analyzed.
Creating a Codebook
Entering Data
• Entering data is simple after the first two steps are complete, as it will be just a
matter of typing in the collected data values according to your specifications in the
variable view.
• Table 4-2 contains example data for you to use to practice making a codebook and
entering data. Once the prior procedures are completed, you should obtain a data
set similar to the one shown in Figure 4-26. Note that Figure 4-26 is not in exactly
the same format as you will see in SPSS.
Table 4-2
Codebook of
the Sample
Data Set
Summary
• Excel is a part of Microsoft Office, and the most widely used spreadsheet software
that supports a variety of analytical efforts, including data management and data-
driven analytical techniques.
• Using the Quick Access toolbar and Ribbon at the top of the screen, you can use
various menus and commands that are designed to help you quickly access the
commands you need to complete a task. Additionally, Excel provides numerous
formulas and functions that allow you to quickly make specific calculations. Data
can be directly entered into Excel, or different types of data files, such as text or CSV
files, can be imported into Excel.
• SPSS is a statistical software package that assists us in efficiently analyzing data to
answer evidence-based practice and research questions, and it is one of the most
widely used statistical software packages available.
Summary
• There are three major file types in SPSS: data files, syntax files, and output files.
Menus in SPSS are categorized into windows and general-purpose, data definition,
and/or data analysis drop-down menus.
• Entering data begins with defining variables in variable view. Then, a researcher
creates a codebook that provides information about the variables in a data set.
This should help a researcher with data entry.
• Data can be either directly entered into SPSS, or different types of data files such
as text or Excel files can be imported into SPSS.
References
• IBM Corp. (2017). IBM SPSS Statistics for Windows, Version 25.0. Armonk, NY: IBM
Corp.
• Potvin Kent, M., Pauzé, E., Roy, E. A., de Billy, N., & Czoli, C. (2019). Children and
adolescents’ exposure to food and beverage marketing in social media apps.
Pediatric Obesity, 14(6), e12508.