Scatter Plots with Error Bars

Similar documents
Scientific Graphing in Excel 2010

There are six different windows that can be opened when using SPSS. The following will give a description of each of them.

Prism 6 Step-by-Step Example Linear Standard Curves Interpolating from a standard curve is a common way of quantifying the concentration of a sample.

Using SPSS, Chapter 2: Descriptive Statistics

Excel Tutorial. Bio 150B Excel Tutorial 1

Dealing with Data in Excel 2010

GeoGebra Statistics and Probability

Regression Clustering

Gestation Period as a function of Lifespan

SPSS Manual for Introductory Applied Statistics: A Variable Approach

Lin s Concordance Correlation Coefficient

Excel -- Creating Charts

Gamma Distribution Fitting

Create Charts in Excel

Creating an Excel XY (Scatter) Plot

Statgraphics Getting started

Excel Math Project for 8th Grade Identifying Patterns

Microsoft Office PowerPoint Creating a new presentation from a design template. Creating a new presentation from a design template

Data exploration with Microsoft Excel: analysing more than one variable

Data Visualization. Prepared by Francisco Olivera, Ph.D., Srikanth Koka Department of Civil Engineering Texas A&M University February 2004

CHARTS AND GRAPHS INTRODUCTION USING SPSS TO DRAW GRAPHS SPSS GRAPH OPTIONS CAG08

Bill Burton Albert Einstein College of Medicine April 28, 2014 EERS: Managing the Tension Between Rigor and Resources 1

Advanced Microsoft Excel 2010

How to make a line graph using Excel 2007

Appendix 2.1 Tabular and Graphical Methods Using Excel

Directions for Frequency Tables, Histograms, and Frequency Bar Charts

Excel Unit 4. Data files needed to complete these exercises will be found on the S: drive>410>student>computer Technology>Excel>Unit 4

Figure 1. An embedded chart on a worksheet.

Petrel TIPS&TRICKS from SCM

Describing, Exploring, and Comparing Data

NCSS Statistical Software Principal Components Regression. In ordinary least squares, the regression coefficients are estimated using the formula ( )

Doing Multiple Regression with SPSS. In this case, we are interested in the Analyze options so we choose that menu. If gives us a number of choices:

Sample Table. Columns. Column 1 Column 2 Column 3 Row 1 Cell 1 Cell 2 Cell 3 Row 2 Cell 4 Cell 5 Cell 6 Row 3 Cell 7 Cell 8 Cell 9.

Formulas, Functions and Charts

Data Analysis. Using Excel. Jeffrey L. Rummel. BBA Seminar. Data in Excel. Excel Calculations of Descriptive Statistics. Single Variable Graphs

Chapter 4 Creating Charts and Graphs

Engineering Problem Solving and Excel. EGN 1006 Introduction to Engineering

Creating a Test in Blackboard

Intermediate PowerPoint

Below is a very brief tutorial on the basic capabilities of Excel. Refer to the Excel help files for more information.

Chapter 5 Analysis of variance SPSS Analysis of variance

CREATING EXCEL PIVOT TABLES AND PIVOT CHARTS FOR LIBRARY QUESTIONNAIRE RESULTS

EXCEL Tutorial: How to use EXCEL for Graphs and Calculations.

How To Run Statistical Tests in Excel

Confidence Intervals for One Standard Deviation Using Standard Deviation

Introduction to Microsoft Excel 2007/2010

GeoGebra. 10 lessons. Gerrit Stols

One-Way ANOVA using SPSS SPSS ANOVA procedures found in the Compare Means analyses. Specifically, we demonstrate

Working with Excel in Origin

5 Correlation and Data Exploration

Comparing two or more groups with: Box and Whisker Plots

Using Excel for descriptive statistics

Plotting: Customizing the Graph

Coins, Presidents, and Justices: Normal Distributions and z-scores

Using Microsoft Excel to Plot and Analyze Kinetic Data

8. Comparing Means Using One Way ANOVA

Modifying Colors and Symbols in ArcMap

Exercise 1.12 (Pg )

Microsoft Excel Tutorial

MEASURES OF VARIATION

Kaplan-Meier Survival Analysis 1

Data Visualization. Brief Overview of ArcMap

Standard Deviation Estimator

PERFORMING REGRESSION ANALYSIS USING MICROSOFT EXCEL

Updates to Graphing with Excel

Data representation and analysis in Excel

In this example, Mrs. Smith is looking to create graphs that represent the ethnic diversity of the 24 students in her 4 th grade class.

This activity will show you how to draw graphs of algebraic functions in Excel.

4. Descriptive Statistics: Measures of Variability and Central Tendency

Summary of R software commands used to generate bootstrap and permutation test output and figures in Chapter 16

University of Arkansas Libraries ArcGIS Desktop Tutorial. Section 2: Manipulating Display Parameters in ArcMap. Symbolizing Features and Rasters:

SPSS Tests for Versions 9 to 13

NCSS Statistical Software

Simple Linear Regression, Scatterplots, and Bivariate Correlation

(Least Squares Investigation)

ITS Training Class Charts and PivotTables Using Excel 2007

Summary of important mathematical operations and formulas (from first tutorial):

MetroBoston DataCommon Training

Simple Predictive Analytics Curtis Seare

Descriptive Statistics

Microsoft Excel 2010 Pivot Tables

FREE FALL. Introduction. Reference Young and Freedman, University Physics, 12 th Edition: Chapter 2, section 2.5

Plotting Data with Microsoft Excel

Drawing a histogram using Excel

Information Literacy Program

STC: Descriptive Statistics in Excel Running Descriptive and Correlational Analysis in Excel 2013

Directions for using SPSS

Mixed 2 x 3 ANOVA. Notes

Market Pricing Override

Business Objects Enterprise version 4.1. Report Viewing

Lab 11: Budgeting with Excel

SPC Response Variable

If there is not a Data Analysis option under the DATA menu, you will need to install the Data Analysis ToolPak as an add-in for Microsoft Excel.

Microsoft Excel 2010 Charts and Graphs

Years after US Student to Teacher Ratio

Creating Charts and Graphs

Creating and Formatting Charts in Microsoft Excel

Hierarchical Clustering Analysis

Transcription:

Chapter 165 Scatter Plots with Error Bars Introduction The procedure extends the capability of the basic scatter plot by allowing you to plot the variability in Y and X corresponding to each point. Each point on the plot represents the mean or median of one or more values for Y and X within a subgroup. Error bars can be drawn in the Y or X direction, representing the variability associated with each Y and X center point value. The error bars may represent the standard deviation (SD) of the data, the standard error of the mean (SE), a confidence interval, the data range, or percentiles. This plot also gives you the capability of graphing the raw data along with the center and error-bar lines. This procedure makes use of all of the additional enhancement features available in the basic scatter plot, including trend lines (least squares), confidence limits, polynomials, splines, loess curves, and border plots. The following graphs are examples of scatter plots with error bars that you can create with this procedure. This chapter contains information only about options that are specific to the procedure. For information about the other graphical components and scatter-plot specific options available in this procedure (e.g. regression lines, border plots, etc.), see the chapter on Scatter Plots. 165-1

Data Structure This procedure accepts data in four different input formats. The type of plot that can be created depends on the input format. A grouping variable may be used to divide the points into groups (e.g., age group or gender). Missing values are handled according to the Missing Values input option. Y and/or X Error Bars (One Y, One X, and a Subgroup (Subject) Variable) In this type, Y and X values are contained in two separate columns. A required Subgroup (Subject) Variable is used to break the Y and X values into subgroups for mean and variance calculations. Each center point on the plot and the associated error bars correspond to the average (or median) Y and X values and associated variability computed for each unique subgroup variable value. A separate point is plotted for each subgroup. One Y Variable, One X Variable, and a Subgroup (Subject) Variable Subject Y X 1 13.15 71.65 1 7.89 73.73 1 11.73 72.02 2 78.6 77.8 2 82.14 78.78 2 82.73 81.05 3 90.25 57.62 3 96.07 58.67 3 95.14 59.67 4 69.6 36.98 4 62.37 36.77 4 67.99 36.05 165-2

Y and/or X Error Bars (Data for Both Y and X in Multiple Columns) In this type, each subgroup (or subject ) is represented by a single row, with multiple Y and X columns entered for each individual. Each point on the plot and the associated error bars correspond to the average (or median) Y and X values and the associated variability computed for each row. A separate point is plotted for each row. Data for Y and X in Multiple Columns Subject Y_1 Y_2 Y_3 X_1 X_2 X_3 1 13.15 7.89 11.73 71.65 73.73 72.02 2 78.6 82.14 82.73 77.8 78.78 81.05 3 90.25 96.07 95.14 57.62 58.67 59.67 4 69.6 62.37 67.99 36.98 36.77 36.05 Y Error Bars (Data for Y in Multiple Columns with One X Variable) In this type, each subgroup (or subject ) is represented by a single row, with multiple Y columns and one X column entered for each individual. Each point on the plot and the associated error bars correspond to the average (or median) Y values and the Y variability computed for each row. A separate point is plotted for each row. Data for Y in Multiple Columns with One X Variable Subject Y_1 Y_2 Y_3 X 1 13.15 7.89 11.73 71.65 2 78.6 82.14 82.73 77.8 3 90.25 96.07 95.14 57.62 4 69.6 62.37 67.99 36.98 X Error Bars (Data for X in Multiple Columns with One Y Variable) In this type, each subgroup (or subject ) is represented by a single row, with multiple X columns and one Y column entered for each individual. Each point on the plot and the associated error bars correspond to the average (or median) X values and the X variability computed for each row. A separate point is plotted for each row. Data for X in Multiple Columns with One Y Variable Subject Y X_1 X_2 X_3 1 13.15 71.65 73.73 72.02 2 78.6 77.8 78.78 81.05 3 90.25 57.62 58.67 59.67 4 69.6 36.98 36.77 36.05 Lines and Border Plots All regression lines, border plots, and other calculations are made using the center points (means and/or medians), not the raw data. The raw data, however, can be included on the plot. 165-3

Procedure Options This section describes the options available in the Scatter Plot with Error Bars procedure. Variables Tab This panel specifies which variables are used in the scatter plot with error bars. Data Input Type There are two ways to organize the data in the database for input into this procedure: Y and/or X Error Bars (One Y, One X, and a Subgroup (Subject) Variable) In this type, Y and X values are contained in two separate columns. A required Subgroup (Subject) Variable is used to break the Y and X values into subgroups for mean and variance calculations. Each center point on the plot and the associated error bars correspond to the average (or median) Y and X values and associated variability computed for each unique subgroup variable value. A separate point is plotted for each subgroup. Y and/or X Error Bars (Data for Both Y and X in Multiple Columns) In this type, each subgroup (or subject ) is represented by a single row, with multiple Y and X columns entered for each individual. Each point on the plot and the associated error bars correspond to the average (or median) Y and X values and the associated variability computed for each row. A separate point is plotted for each row. If only one column is entered for either X or Y, no error bars will be plotted on the corresponding axis. Y Error Bars (Data for Y in Multiple Columns with One X Variable) In this type, each subgroup (or subject ) is represented by a single row, with multiple Y columns and one X column entered for each individual. Each point on the plot and the associated error bars correspond to the average (or median) Y values and the Y variability computed for each row. A separate point is plotted for each row. If only one column is entered for Y, no error bars will be plotted. X Error Bars (Data for X in Multiple Columns with One Y Variable) In this type, each subgroup (or subject ) is represented by a single row, with multiple X columns and one Y column entered for each individual. Each point on the plot and the associated error bars correspond to the average (or median) X values and the X variability computed for each row. A separate point is plotted for each row. If only one column is entered for X, no error bars will be plotted. Variables Data Input Type = Y and/or X Error Bars (One Y, One X, and a Subgroup (Subject) Variable) Y (Vertical) Variable Specify a column whose values are to be summarized using the Subgroup (Subject) Variable. The means (or medians) are plotted on the vertical axis. Each Y center point value on the plot and the associated vertical error bars correspond to the mean (or median) Y values and variability computed for each unique subgroup variable value. 165-4

X (Horizontal) Variable Specify a column whose values are to be summarized using the Subgroup (Subject) Variable. The means (or medians) are plotted on the horizontal axis. Each X center point value on the plot and the associated horizontal error bars correspond to the mean (or median) X values and variability computed for each unique subgroup variable value. Subgroup (Subject) Variable The values in this column are used to separate the data into subgroups for summary statistic calculations. Summary measures (mean, median, and variability) are calculated for both the Y and X variables for each unique value in this variable. A separate point is plotted for each unique subgroup variable value. Data Labels If you activate Data Labels on the plot, the values in this variable will be used to label the individual points. Variables Data Input Type = Y and/or X Error Bars (Data for Both Y and X in Multiple Columns) Y (Vertical) Variable(s) Specify one or more columns containing data to be summarized and plotted on the vertical axis. The mean, median, and variability for all of columns entered will be calculated within each row. Each Y center point value on the plot and the associated vertical error bars correspond to the mean (or median) Y values and variability computed for each row. If only one column is entered, no vertical error bars will be plotted. X (Horizontal) Variable(s) Specify one or more columns containing data to be summarized and plotted on the horizontal axis. The mean, median, and variability for all of columns entered will be calculated within each row. Each X center point value on the plot and the associated horizontal error bars correspond to the mean (or median) X values and variability computed for each row. If only one column is entered, no horizontal error bars will be plotted. Variables Data Input Type = Y Error Bars (Data for Y in Multiple Columns with One X Variable) Y (Vertical) Variable(s) Specify one or more columns containing data to be summarized and plotted on the vertical axis. The mean, median, and variability for all of columns entered will be calculated within each row. Each Y center point value on the plot and the associated vertical error bars correspond to the mean (or median) Y values and variability computed for each row. If only one column is entered, no vertical error bars will be plotted. X (Horizontal) Variable Specify a column with values to be plotted on the horizontal axis. Variables Data Input Type = X Error Bars (Data for X in Multiple Columns with One Y Variable) Y (Vertical) Variable Specify a column with values to be plotted on the vertical axis. 165-5

X (Horizontal) Variable(s) Specify one or more columns containing data to be summarized and plotted on the horizontal axis. The mean, median, and variability for all of columns entered will be calculated within each row. Each X center point value on the plot and the associated horizontal error bars correspond to the mean (or median) X values and variability computed for each row. If only one column is entered, no horizontal error bars will be plotted. Variables Common Options Grouping (Symbol) Variable This variable may be used to separate the observations into groups. For example, you might want to use different plotting symbols to distinguish observations from different groups. You designate the grouping variable here. Each unique value of this column is plotted with a different symbol. The symbols are selected by clicking on the plot format button and then clicking on the symbol format button. Data Label Variable (Not available if Data Input Type = Y and/or X Error Bars (One Y, One X, and a Subgroup (Subject) Variable) ) A data label is text that is displayed beside each point. A column containing the data labels is specified here. The values may be text or numeric. The data labels will not be shown unless you activate them by clicking the plot format button and checking Labels. When Data Input Type = Y and/or X Error Bars (One Y, One X, and a Subgroup (Subject) Variable), the Subgroup (Subject) Variable values are used as the data labels on the plot (when activated). Missing Values Missing Values This option allows you to specify how rows with missing values are handled. The options are Include Rows with Missing Y s or X s Rows that contain either a missing Y value or a missing X value are included in mean, median, and variance calculations. Exclude Rows with Missing Y s or X s Rows that contain either a missing Y value or a missing X value are not included in mean, median, and variance calculations. If a missing Y or X value is encountered, the entire row is ignored. Format Options Variable Names This option selects whether to display variable names, labels, or both. Value Labels This option selects whether to display only values, value labels, or both. Use this option if you want the group variable to automatically attach labels to the values (like 1=Yes, 2=No, etc.). 165-6

Scatter Plot with Error Bars Format Format Click the format button to change the plot settings (see Scatter Plot with Error Bars Window Options below). Edit During Run Checking this option will cause the Scatter Plot Format window to appear when the procedure is run. This allows you to modify the format of the graph with the actual data. Symbol Size Options (Not available if Data Input Type = Y and/or X Error Bars (One Y, One X, and a Subgroup (Subject) Variable) ) Symbol Size Variable This optional variable can be used to specify a proportional size for the data points. Scatter Plot with Error Bars Window Options This section describes the specific options available on the Scatter Plot with Error Bars window, which is displayed when the Plot Format button is clicked. For information about the other graphical components and scatter-plot specific options available in this procedure (e.g. symbols, regression lines, data labels, etc.), see the chapter on Scatter Plots. Common plot options, such as axes, labels, legends, and titles are documented in the Graphics Components chapter. Scatter Plot Tab Estimation of Center You can choose whether to plot means or medians for Y and X. 165-7

Symbols You can choose whether to plot the center points, the raw data values, or both. You can also modify the appearance of all symbols on the plot. Variation (Error Bars) You can modify the content and appearance of the vertical and horizontal error bars using these options. We will highlight the most commonly-used options. Y and X Error Bar Lines Select the error bars to be displayed. 165-8

Line Color and Style Specify the color and style of error bar lines. The lines and symbols are completely customizable. 165-9

Type Specify whether to use the standard deviation (SD) of the data, the standard error of the mean (SE), a confidence interval, the data range, or percentiles in computing the length of the error bars and their bounds. 165-10

Direction Specify whether error bars extend up or down (right or left) from the center point. Crossbars Specify whether or not to include crossbars and their size. 165-11

Example 1 Creating a Scatter Plot with Error Bars using a Subgroup (Subject) Variable This example demonstrates how to generate a simple scatter plot with error bars from data that includes a subgroup variable. The data used are contained in the ScatPlotError1 dataset. In this example, Response is the Y variable and Time is the X variable. Each response is repeated three times for each time value. You may follow along here by making the appropriate entries or load the completed template Example 1 by clicking on Open Example Template from the File menu of the procedure window. 1 Open the ScatPlotError1 dataset. From the File menu of the NCSS Data window, select Open Example Data. Click on the file ScatPlotError1. Click Open. 2 Open the window. Using the Graphics menu or the Procedure Navigator, find and select the procedure. On the menus, select File, then New Template. This will fill the procedure with the default template. 3 Specify the variables. For Data Input Type select Y and/or X Error Bars (One Y, One X, and a Subgroup (Subject) Variable). For Y (Vertical) Variable enter Response. For X (Horizontal) Variable enter Time. For Subgroup (Subject) Variable enter Subject. For Grouping (Symbol) Variable enter Rate. 4 Edit the Plot. Click on the Plot Format button. On the Scatter Plot tab, change the Y Error Bar Variation Line Type to Standard Deviation (SD). Select the More Lines tab, and put a checkmark next to Line under Connect Center Points. Click OK to save the plot settings. 5 Run the procedure. From the Run menu, select Run Procedure. Alternatively, just click the green Run button. 165-12

Scatter Plot Output 165-13

Example 2 Creating a Scatter Plot with Error Bars from Data with Y s and X s in Multiple Columns This example demonstrates how to generate a simple scatter plot with both Y and X error bars from data where X and Y measurements are stored in multiple columns. In this example, we ll plot medians instead of means. The data used are contained in the ScatPlotError2 dataset. You may follow along here by making the appropriate entries or load the completed template Example 2 by clicking on Open Example Template from the File menu of the procedure window. 1 Open the ScatPlotError2 dataset. From the File menu of the NCSS Data window, select Open Example Data. Click on the file ScatPlotError2. Click Open. 2 Open the window. Using the Graphics menu or the Procedure Navigator, find and select the procedure. On the menus, select File, then New Template. This will fill the procedure with the default template. 3 Specify the variables. For Data Input Type select Y and/or X Error Bars (Data for Both Y and X in Multiple Columns). For Y (Vertical) Variable(s) enter Y_1, Y_2, Y_3. For X (Horizontal) Variable(s) enter X_1, X_2, X_3. For Grouping (Symbol) Variable enter Group. 4 Edit the Plot. Click on the Plot Format button. On the Scatter Plot tab, change the X Center Estimation Type to Median. On the Scatter Plot tab, put a checkmark next to Raw Data under Symbols. Click OK to save the plot settings. 5 Run the procedure. From the Run menu, select Run Procedure. Alternatively, just click the green Run button. 165-14

Scatter Plot Output 165-15

Example 3 Creating a Scatter Plot with Y Error Bars from Data with Multiple Y Variables and One X Variable This example shows how to generate a simple scatter plot with Y error bars from data where Y measurements are stored in multiple columns. The data used are contained in the ScatPlotError2 dataset. You may follow along here by making the appropriate entries or load the completed template Example 3 by clicking on Open Example Template from the File menu of the procedure window. 1 Open the ScatPlotError2 dataset. From the File menu of the NCSS Data window, select Open Example Data. Click on the file ScatPlotError2. Click Open. 2 Open the window. Using the Graphics menu or the Procedure Navigator, find and select the procedure. On the menus, select File, then New Template. This will fill the procedure with the default template. 3 Specify the variables. For Data Input Type select Y Error Bars (Data for Y in Multiple Columns with One X Variable). For Y (Vertical) Variable(s) enter Y_1, Y_2, Y_3. For X (Horizontal) Variable enter X_1. For Grouping (Symbol) Variable enter Group. 4 Run the procedure. From the Run menu, select Run Procedure. Alternatively, just click the green Run button. 165-16

Scatter Plot Output 165-17

Example 4 Creating a Scatter Plot with 95% Confidence Interval Limits for X from Data with Multiple X Variables and One Y Variable This example shows how to generate a simple scatter plot with 95% confidence intervals for X from data where X measurements are stored in multiple columns. The data used are contained in the ScatPlotError2 dataset. You may follow along here by making the appropriate entries or load the completed template Example 3 by clicking on Open Example Template from the File menu of the procedure window. 1 Open the ScatPlotError2 dataset. From the File menu of the NCSS Data window, select Open Example Data. Click on the file ScatPlotError2. Click Open. 2 Open the window. Using the Graphics menu or the Procedure Navigator, find and select the procedure. On the menus, select File, then New Template. This will fill the procedure with the default template. 3 Specify the variables. For Data Input Type select X Error Bars (Data for X in Multiple Columns with One Y Variable). For Y (Vertical) Variable enter Y_1. For X (Horizontal) Variable(s) enter X_1, X_2, X_3. For Grouping (Symbol) Variable enter Group. 4 Edit the Plot. Click on the Plot Format button. On the Scatter Plot tab, put a checkmark next to Raw Data under Symbols. On the Scatter Plot tab, change the X Error Bar Variation Line Type to Confidence Interval. Click OK to save the plot settings. 5 Run the procedure. From the Run menu, select Run Procedure. Alternatively, just click the green Run button. 165-18

Scatter Plot Output 165-19