MUST HAVE THE MINITAB STATISTICS SOFTWARE
Using Minitab for Statistical Analysis
Davenport University
Statistics Courses
Created by
David Poock
Deb Steiner
Updated by
John Suttkus
Preface
This document only provides basic information on using fundamental commands in Minitab to analyze data. Any interpretation of results is the responsibility of the instructor. The included sample output is only used to demonstrate the typical results.
We are thankful for the work of Nicholas Scheal, an adjunct instructor at Davenport University, in creating the first version of this guide.
Table of Contents General Minitab Information 5 Downloading a Copy of Minitab from the Davenport Library Website 5 Starting Minitab on a Davenport computer 5 Session and Worksheet Windows 5 Entering Data into a Minitab Worksheet 6 Saving Minitab worksheets/projects: 7 Copying and Pasting into a Word Processor: 8 Editing a Graph in a Word Processor: 8 Creating Tables 9 Frequency Tables - Individual Values 9 Frequency Tables – Using class intervals 10 Creating Graphs 12 Histogram 12 Frequency Polygon 14 Ogive 15 Dotplot 15 Stemplot 17 Bar Chart (or Bar Graph) 18 Pareto Chart 19 Pie Chart 20 Scatterplot 21 Time-Series Graph 21 Boxplot 22 Calculating Descriptive Statistics 24 Correlation & Regression Analysis 26 Correlation Coefficient and P-Value 26 Regression Equation and R-squared 26 Fitted Line Plot 28 Probability Distributions 29 Binomial Probability Distribution 29 Poisson Probability Distribution 30 Uniform Probability Distribution 30 Normal Probability Distribution 31 Confidence Intervals 33 Confidence interval: population mean, μ 33 Confidence interval: population proportion, p 34 Hypothesis Testing 35 Hypothesis Testing: population mean, μ 35 Hypothesis Testing: population proportion, p 36
Minitab Guide Fall 2011 – Updated Spring 2015 1
Minitab Guide Fall 2011 – Updated Spring 2016 2
General Minitab Information
Downloading a Copy of Minitab from the Davenport Library Website
On your home computer or laptop, click here, or log in to your Davenport STUDENT CONNECTION webpage. Scroll down to STUDENT TOOLS and click on the Library link. Under , click on MiniTab and then download Minitab for either a PC or a MAC. If you have trouble installing Minitab on your home computer, please call IT at 1-877-899-1499.
Starting Minitab on a Davenport computer
If you are on a Davenport computer, type Minitab in the Search Windows box at the bottom of the desktop screen and then select Minitab.
MiniTab is a statistical software package designed for easy interactive use. For a quick introduction to Minitab, go to http://www.minitab.com/en-us/support/documentation/ and click on Getting Started with Minitab 17.
Session and Worksheet Windows
After opening Minitab, you will see a display of its two main windows: the Session window at the top and the Worksheet window at the bottom. The Project window is minimized below the Worksheet window. Only one window will be active at any time. You can make a window active by clicking in it or choosing it from the Window menu.
Window menu.
This is the minimized Project window.
This is the Worksheet window.
This is the Session window.
The Session window displays calculated results in text format. Text in this window can be formatted, copied and pasted into another document, or deleted.
The Worksheet window consists of a spreadsheet for entering data in columns. Minitab allows you to have multiple worksheets open at one time. When you have more than one worksheet in a project, the active worksheet is indicated by three asterisks (***) following the worksheet name in the title bar. If multiple worksheets are open, commands will act only upon the data in the active worksheet. You can make a particular worksheet active by clicking in it or choosing it from the Window menu. You can also toggle between the worksheets by hitting CTRL D.
Entering Data into a Minitab Worksheet
In Minitab, there are three types of data: (1) numeric data (numbers), (2) text data (characters), and (3) date/time data.
The data columns are identified as C1, C2, C3, etc. Immediately under these column labels, you will find an empty gray cell to enter the column title (above row 1 of the data set). This is where you can label each column with a name that represents the data stored in that column. Many of the operations that we will be performing are done by referring to specific columns, so to help, Minitab lets you give the columns a name so you know what is in it. For example, if you have variables that are pulse rates, then you can call that column “Pulse.”
It is wise to enter a meaningful name for the different columns of data so it becomes easy to keep track of what’s stored in each column in the dataset.
The three asterisks indicate that this is the active worksheet.
Type in the column names here.
Entry of sample data is very simple. Click on the first cell of the desired column, type a number, then press the Enter key. Then type a second number and press the Enter key again. Continue this process until all of the sample data have been entered. If you make a mistake, simply click on the wrong entry, type in the correct value, and hit Enter.
Note, the direction of the arrow in the upper left corner of the worksheet tells you the entry direction when you are entering data. (We call this arrow the data entry direction arrow.)
To enter data column wise, click the data entry direction arrow to make it point down. After you type a value and press Enter, the active cell moves down.
To enter data row wise, click the data entry direction arrow to make it point to the right. After you type a value and press Enter, the active cell moves to the right.
Although Minitab worksheets have rows and columns into which you can type values and generate commands, it does not work exactly like a spreadsheet in Excel. The functionality of the worksheets in Minitab is generally defined by columns rather than by individual cells. For example, a single column can contain only one type of data (text, numeric, or date/time). In addition, if you want to assign a formula in the worksheet so that calculated values can be updated automatically when data are added or changed, you must assign the formula to an entire column, not to individual cells.
Tip: To zoom in or out to increase or decrease the size and number of cells displayed in the worksheet, press the CTRL key while scrolling your mouse wheel when the worksheet is active.
Many times data can be copied and pasted directly into Minitab from a spreadsheet, document, or website. Make sure you double check that the data has been copied into the correct columns in Minitab. You may have to adjust the spaces between data values before coping and pasting so the data is pasted into the correct column.
Saving Minitab worksheets/projects:
After entering your data, you can save the dataset as a Minitab worksheet as follows:
1. Click on File.
2. Click on Save Current Worksheet As …
3. A dialog box will then be displayed. In the “Save in” box, enter the location where you want the worksheet saved. In the “File name” box, enter the name of the file. You can omit the extension of .MTW; it will automatically be provided by Minitab.
4. Click on Save.
The above commands will only save the active Minitab worksheet. If you have multiple worksheets open and/or have done some calculations and created some graphs, you will want to save all of this together in a Minitab Project. You can save your project as follows:
1. Click on File.
2. Click on Save Project As …
3. A dialog box will then be displayed. In the “Save in” box, enter the location where you want the project saved. In the “File name” box, enter the name of the project. You can omit the extension of .MPJ; it will automatically be provided by Minitab.
4. Click on Save.
Again, saving the Minitab project saves all output in the session window, any graphs that were created, and any alterations made to the worksheet(s). When you reopen the project, you can resume working where you left off.
Copying and Pasting into a Word Processor:
To copy a stem-and-leaf plot, descriptive stats, regression analysis results, a confidence interval, or results of a hypothesis test from the session window into a word processor, copy and paste as usual. Click and drag to highlight what you want to copy. Click on “Edit” and choose “Copy.” Alternatively, after highlighting, right-click and choose Copy, or hit CTRL C. Then go to the word processor and choose “Paste.” Alternatively, right click and choose Paste, or hit CTRL V.
To copy a graph into a word processor, click on the graph then click “Edit” and choose “Copy graph.” Then go to the word processor and choose “Paste.” The same alternative methods work here. Make sure you clicked on the graph first. Then either right click and choose Copy, or hit CTRL C. (If you don’t click on the graph, it will copy something from the session window or worksheet instead of the graph.) Once in the word processor, either right click and choose “Paste,” or hit CTRL V.
You can resize the graph by (single) clicking on the graph and dragging any of the corners towards the center of the graph. ONLY use the corners, as this will preserve the ratio.
Editing a Graph in a Word Processor:
When a graph has been copied into a word processor, it can still be edited. Double click on the graph. It takes a few seconds, but you will see slash marks (////) appear all around the graph (see below). While the slash marks are around the graph, your word processor is actually transferring your work to Minitab. You are able to alter colors, fonts, and other aspects of the graph just as if you were in Minitab creating the graph. To finish, click away from the graph outside of the slash marks. This returns the graph to your word processor and the slash marks go away.
Creating Tables
Many of the examples in this manual make use of the female pulse rate data in the FHEALTH.MTW worksheet provided in the STAT 220 textbook, Elementary Statistics (11th Edition) by Mario F. Triola. (Data Set 1, Appendix B, page 767, Column 5).
For your convenience, the dataset has also been provided below:
Frequency Tables - Individual Values
To create a frequency table of individual values, do the following:
1. Enter or retrieve the data into a Minitab column.
2. Click Stat. Choose Tables and then choose Tally Individual Variables.
3. Enter the variables you want to make a frequency table for in the Variables box. Immediately below is the option for Counts (frequencies), Percents (relative frequencies), Cumulative Counts (cumulative frequencies), and Cumulative Percents (cumulative relative frequencies). The nice thing about Minitab is that you can create all the frequency tables in a single step. Choose any of the options that you want to use by checking each one’s box. (If you know you are going to look at all four, you can check all four and only have to make one table.)
4. Click OK.
These tables will be displayed in the Session window.
Using the female pulse rate data (column C5) in the FHEALTH.MTW worksheet, the following results were obtained:
Tally for Discrete Variables: PULSE
PULSE Count Percent CumCnt CumPct
60 3 7.50 3 7.50
64 4 10.00 7 17.50
68 5 12.50 12 30.00
72 8 20.00 20 50.00
76 6 15.00 26 65.00
80 6 15.00 32 80.00
88 5 12.50 37 92.50
96 1 2.50 38 95.00
104 1 2.50 39 97.50
124 1 2.50 40 100.00
N= 40
Here, the frequency table gives the number of times each individual value appeared. If we wanted to create a frequency table with class intervals, we could now use the tally counts found above to see how many data values fall into each class. For example, we would see that there are 12 data values falling into the class of 60 – 69 (3 at 60, 4 at 64, and 5 at 68, for a total of 12).
Another way to obtain a frequency distribution with data separated into classes is to generate a stemplot (described later in this handout, page 16). The frequency counts for the classes can be found by simply counting the number of digits to the right of each stem.
There is also a third method that we can use in Minitab to create a frequency distribution with the data separated into classes. The steps are given next.
Frequency Tables – Using class intervals
To create a frequency table using class intervals, do the following:
1. Enter or retrieve the data into a Minitab column.
2. Click Data. Choose Code and then choose Numeric to Text. This will change the individual values into the values of the classes that you want for your frequency table.
3. In Code data from columns enter the column of the original data, and enter a new column for Store coded data in columns (this is where the output will go).
4. In Original values you need to specify each range of numbers. For example, 60:69 is how you type in 60, 61, …, 69. Then in the New box directly across from it, type in 60 - 69. This replaces any values of 60, 61, …, 69 with the new label of the class.
5. Repeat this for each of the classes (see below).
6. Click OK.
To create the frequency table with classes, create the frequency table as before (Stat – Tables –Tally Individual Variables) using the new data in the stored column. The difference is that now instead of using the original data you use the new column of coded data (that shows the classes).
Note, the table generated by Minitab using this method doesn’t always have the class intervals in numerical order. For example, Minitab created the frequency and relative frequency tables below for the female pulse data. As you can see, the classes are not listed in order, which will cause the cumulative frequencies and cumulative percents to be inaccurate. Therefore, it is suggested that this method only be used for “counts” and “percents”, and not for cumulative totals. Instead, after rearranging the classes from lowest to highest, the cumulative totals can be found by hand.
C2 Count Percent
100 - 109 1 2.50
120 - 129 1 2.50
60 - 69 12 30.00
70 - 79 14 35.00
80 - 89 11 27.50
90 - 99 1 2.50
N= 40
(Note also that if a class has a frequency of 0, it will not show up in the table.)
Creating Graphs
Most of the graphs we will create in Minitab can be found under the Graph menu item. We will create the following graphs: Histogram, Relative Frequency Histogram, Frequency Polygon, Ogive, Bar Chart, Dotplot, Stem-and-leaf Plot, Pie Chart, Scatterplot, Time-series Plot, and Boxplot. (We will also create a Pareto Chart, but this is found under the Stat menu item.)
Histogram
A histogram can be used to explore the distribution of a quantitative data set. It examines the shape and spread of sample data. A histogram is constructed by drawing bars (rectangles) for each class of data (either using midpoints or class boundaries (cutpoints) ). The height of each bar is the frequency of the class.
Below is the Minitab procedure for generating a Histogram:
1. Enter the data in a Minitab column, such as column C1. If the data are already stored in a Minitab worksheet, retrieve the worksheet.
2. Click on the main menu item Graph.
3. Select Histogram and click on the option of Simple. Then click OK.
4. Place your cursor in the “Graph Variables” box and either type in the column label that contains the data you want to use (such as C1) or double click on the column in the left box.
5. If you want to give the histogram a title, click on Labels and type the title in. You can also add grid lines by clicking Scale and clicking the Gridlines tab (Use MAJOR ticks).
6. Click OK to display the Histogram.
Using Minitab, the following histogram for the female pulse rates was created.
Here, the vertical axis represents the frequency. If you want to make a relative frequency histogram (instead of the default which is frequency) then before step 6 above, click on Scale and select the Y-scale Type tab. For a relative frequency histogram, choose the Percent button and then click OK.
If you want to change the look of the histogram, you can double click on the attribute that you want to change. For example, if you double click on the background, you can change its color. If you double click on any of the titles, you can change the font, size, orientation, etc. If you double click on the bars of the histogram you can change the color, pattern, etc. (You can change color under the first tab that says “Attributes”.)
Histograms created in Minitab divide sample values into intervals called bins . Bins are intervals used to sort sample data for graphing. In Minitab, histograms plot bars that represent the number of values falling into each bin (its frequency). Note: observations that fall exactly on an interval boundary are included in the interval to the right (or left, if it is the last bin).
The number of bins influences the appearance of a graph. If there are too few bins, the graph will be unrefined and represent the data poorly. If there are too many bins, many of them will be unoccupied and the graph may have too much detail. For example, the histograms below represent the same data:
Minitab automatically calculates and uses an optimal number of bins. The middle graph (15 bins) is the Minitab default for this dataset. However, you can change the number of bins, as desired. Bins can be defined by either their midpoints (center values) or their cutpoints (class boundaries).
To change the binning of a histogram from midpoint to cutpoint positions (which is how graphs usually look), do the following:
1. Double click anywhere on the X-scale of the histogram.
2. In the Edit Scale pop-up window, click on the Binning tab, select Cutpoint under Interval Type, and then select Midpoint/Cutpoint positions under Interval Definition.
3. You will have to type in the values of the cutpoints in the following fashion: low end: high end / interval length. For example, 10:50/5 starts the first bar (bin) at 10 – 15, the next bar at 15 – 20, and so on up to the last bar of 45 – 50. Also, 0:4/0.5 would have bars (bins) of 0.0 – 0.5, 0.5 – 1.0, ..., 3.5 – 4.0.
4. Click OK.
To see the height (frequency) of a bar, hover your cursor over it.
Frequency Polygon
A frequency polygon is similar to a histogram, but instead of plotting bars with heights corresponding to the frequencies, we plot points at the midpoints of each class interval. The height of a point corresponds to the frequency of that class. The points are then connected with a line.
Here is the Minitab procedure for generating a frequency polygon:
1. Enter the data in a Minitab column, such as column C1. If the data are already stored in a Minitab worksheet, retrieve the worksheet.
2. Click on the main menu item Graph.
3. Select Histogram and click on the option of Simple. Then click OK.
4. Place your cursor in the “Graph Variables” box and either type in the column label that contains the data you want to use (such as C1) or double click on the column in the left box.
5. Click on Data View. Under Data Display, uncheck “Bars” and check Symbols (this makes the dots).
6. Click the Smoother tab. Click on Lowess, and change Degree of smoothing to 0. (this connects the dots).
7. Click OK twice to display the frequency polygon.
The following frequency polygon was created for the female pulse rates. (Note, the default binning was changed to midpoint positions of 65, 75, 85, … 125 using the methods on the previous page.)
Ogive
Here is the Minitab procedure for generating an ogive:
1. Enter the data in a Minitab column, such as column C1. If the data are already stored in a Minitab worksheet, retrieve the worksheet.
2. Click on the main menu item Graph.
3. Select Histogram and click on the option of Simple. Then click OK.
4. Place your cursor in the “Graph Variables” box and either type in the column label that contains the data you want to use (such as C1) or double click on the column in the left box.
5. Click on Scale and then on the Y-Scale Type tab. Check the box for Accumulate values across bins.
6. Click on Data View. Under Data Display, uncheck “Bars” and check Symbols.
7. Click the Smoother tab. Click on Lowess, and change Degree of smoothing to 0.
8. Click OK twice to display the ogive.
Dotplot
Dotplots are used to assess and compare distributions. A dot plot is drawn by placing each value in the data set horizontally in increasing order and placing a dot above the value each time it occurs.
Here is the Minitab procedure for creating a dotplot.
1. Enter the data in a Minitab column, such as column C1. If the data are already stored in a Minitab worksheet, retrieve the worksheet.
2. Click on the main menu item of Graph.
3. Select Dotplot, then choose Simple, and click OK.
4. Place your cursor in the “Graph Variables” box and either type in the column label that contains the data you want to use (such as C1) or double click on the column in the left box.
5. Click OK to display the dotplot.
Shown below is the Minitab dotplot display of the female pulse rates. The original dotplot showed values on the horizontal scale of 63, 72, 81, …, 117, but the dotplot was modified to show the more convenient values of 60, 65, 70, …, 125 instead. This change in the numbers used for the horizontal scale was made by double-clicking on any number on the horizontal scale, selecting the Scale tab, and then typing 60:125/5 in the box labeled Position of ticks.
If possible, Minitab displays a dot for each observation. Otherwise, a dot represents multiple observations with a footnote indicating the maximum number of observations represented by each dot.
Note, you can make several dotplots at one time by entering all the columns of data to plot in the “Graph Variables” box. Minitab displays a separate graph for each column. To panel all graphs on the same page, click on the “Multiple Graphs” box and choose Multiple Variables . Under “Show Graph Variables”, select In separate panels on the same graph.
Note, the dotplots may have different scales. You can make it so the dotplots have the same scale by clicking on Same x, including same bins (see below.)
Stemplot
Minitab can provide stemplots (or stem-and-leaf plots). The textbook notes that a stemplot represents data by separating each value into two parts: the stem (such as the leftmost digit) and the leaf (such as the rightmost digit).
Stemplots are used to examine the shape and spread of sample data. Minitab displays a stem-and-leaf plot in the Session window. The plot is similar to a histogram on its side, however, instead of bars, digits from the actual data values indicate the frequency of each bin (row).
One advantage of the stem-and-leaf plot over frequency distributions and histograms is that the raw data can be retrieved from the stem-and-leaf plot. (Once a frequency distribution or histogram of data is created using classes, the raw data are lost.)
Here is the Minitab procedure for generating a stemplot.
1. Enter the data in a Minitab column, such as column C1. If the data are already stored in a Minitab worksheet, retrieve the worksheet.
2. Click on the main menu item of Graph.
3. Select Stem-and-Leaf.
4. Place your cursor in the “Graph Variables” box and either type in the column label that contains the data you want to use (such as C1) or double click on the column in the left box.
5. If you have a number of groups that you want to make separate stem-and-leaf plots for but the numbers are all in one column, you can use By Variable to separate the column. E.g.: separate by car make, or freshman/sophomore/junior/senior, either of which would be stored in another column.
6. Minitab automatically chooses whether or not to stretch the stem-and-leaf plot. If you do not like the way the stem-and-leaf turned out, you can set the “Increment” to the desired value (such as 10). (You can just delete the one you already made and create a new one).
7. Click OK.
Shown below is the Minitab stem-and-leaf plot that results from the female pulse rates. (Again, these results will be displayed in the Session window.)
Stem-and-leaf of PULSE N = 40
Leaf Unit = 1.0
7 6 0004444
12 6 88888
20 7 22222222
20 7 666666
14 8 000000
8 8 88888
3 9
3 9 6
2 10 4
1 10
1 11
1 11
1 12 4
The above stem-and-leaf plot is the default that is automatically generated by Minitab. In this case, it is an expanded stemplot, with classes of 60-64, 65-69, 70-74, 75-79, and so on.
To obtain a stem-and-leaf plot that is not expanded, enter an Increment value of 10. The new results are shown below.
Stem-and-leaf of PULSE N = 40
Leaf Unit = 1.0
12 6 000444488888
(14) 7 22222222666666
14 8 00000088888
3 9 6
2 10 4
1 11
1 12 4
From the stem-and-leaf plot, you can see that the first five values in the dataset are pulse rates (in beats per minute) of 60, 60, 60, 64, and 64. The maximum pulse rate in the dataset was 124.
The display has three columns:
· The leaves (right) – Each value in the leaf column represents a digit from one observation. The "Leaf Unit" (declared above the plot) specifies which digit is used. In this example, the Leaf Unit is 1.0 so it represents a digit in the unit (or one’s) place value.
· The stem (middle) – The stem value represents the digit immediately to the left of the leaf digit. In the example, the stem value of 6 indicates that the leaves in that row are from observations with values greater than or equal to 60, but less than 70; the stem value of 7 indicates values greater than or equal to 70, but less than 80, and so on.
· Counts (left) – These values represent some cumulative counts – you can ignore this column (it won’t be used).
Bar Chart (or Bar Graph)
(Using either frequencies or relative frequencies)
One of the most common devices for graphically representing qualitative data is a bar chart. A bar chart is constructed by labeling each category on the horizontal axis and the frequency (or relative frequency) of the category on the vertical axis. Bars of equal width are drawn for each category and the height of each bar represents the category’s frequency (or relative frequency).
Use the following steps to construct a bar chart from individual data values (raw data).
1. Enter the data in a Minitab column, such as column C1. If the data are already stored in a Minitab worksheet, retrieve the worksheet.
2. Click on the main menu item Graph. Select Bar Chart.
3. In the “Bars represent” pull-down menu, select Counts of unique values. Click on Simple. Then click OK.
4. In the “Categorical variables” box, click on the column with the data so that the column label (such as C1) or the data name appears in the box.
5. Click on Labels to add a title to the graph. You can add grid lines by clicking Scale and clicking the Gridlines tab (use MAJOR ticks).
6. Click OK to display the bar chart.
You can also have the height of each bar represent the relative frequencies instead of the frequencies. Before step 6 above, in the Bar Chart dialog box, click on Chart Options and select the box Show Y as percent.
Use the following steps to construct a bar chart from a table of values (summarized data).
1. Enter the categories (labels) in C1 and the frequencies or (relative frequencies) in C2. If the data are already stored in a Minitab worksheet, retrieve the worksheet.
2. Click on the main menu item Graph. Select Bar Chart.
3. In the “Bars represent” pull-down menu, select Values from a table. Click on Simple. Then click OK.
4. In the Graph variables box, enter C2 (or the column that contains the frequencies). In the Categorical variable box, enter C1 (or the column that contains the categories you want to use to make the bar chart).
5. Click on Labels to add a title to the graph. You can add grid lines by clicking Scale and clicking the Gridlines tab (use MAJOR ticks).
6. Click OK to display the bar chart.
Pareto Chart
A Pareto chart is a bar graph for qualitative data, with the bars arranged in decreasing order of frequency. The tallest bar is at the left, and the smaller bars are farther to the right.
Here is the Minitab procedure for constructing a Pareto chart:
1. If you have raw data, enter it in column C1 (or any other desired column). If you have summarized data in a table, enter the categories (labels) in one column (such as C1) and the frequencies in a separate column (such as C2).
2. Select the menu items of Stat, Quality Tools, and Pareto Chart.
3. In the Defects or attribute data in: box, enter the column that contains the categories
(labels). This is the only column you need to enter if you have raw data. If the data is
summarized in a table, enter the frequency column in the Frequencies in box.
4. Click Do not combine. If you don’t want the ogive overlapped with the Pareto chart, click
on Options, and check the Do not chart cumulative percent box.
5. Click OK to display the Pareto chart.
Pie Chart
A pie chart is a circle divided into sectors (or wedges). Each sector represents a category of data. The area of each sector is proportional to the frequency of the category.
Here is the procedure for using Minitab to construct a Pie chart from individual data values (raw data).
1. Enter the raw data in column C1 (or any other desired column).
2. Select the main menu item of Graph. Then select Pie Chart.
3. When the dialog box is displayed, select the Chart counts of unique values option. Click in the “Categorical Variables” box. Enter the column that contains the data you want to make a pie chart for.
4. Under Pie chart options you can change the order of the pieces from the order they appear in the data to increasing volume (smallest to largest) or decreasing volume (largest to smallest).
5. Click Labels and choose the Slice Labels tab. Here you can choose to label the slices of the pie with their name and either their frequency or percent (you typically would not do both frequency and percent).
6. Click OK to display the pie chart.
To see the percent of each wedge, hover your cursor over it.
Here is the procedure for using Minitab to construct a Pie chart from a table of values (summarized data).
1. Enter the table in a worksheet – labels in one column, frequencies in another column.
2. Select the main menu item of Graph. Then select Pie Chart.
3. When the dialog box is displayed, select the Chart values from a table option. Click in the “Categorical Variables” box. Enter the column that contains the data you want to make a pie chart for. Click in the “Summary Variables” box and enter the column of the frequency values.
4. Pie Chart Options and Labels work the same as with Pie Charts from individual data. (See steps 4 and 5 on the previous page.)
5. Click OK to display the Pie chart.
Scatterplot
A scatterplot can be very helpful in identifying a relationship between two variables. (In particular, we will be looking for linear relationships in this class.)
Here is the Minitab procedure for generating a scatterplot.
1. Given a collection of paired data, enter the values for one of the variables in a column (such as C1), and enter the corresponding values for the second variable in another column (such as C2). Be sure to enter the two columns of data so that they are matched in the same way that they are paired in the original listing.
2. Click on Graph from the main menu.
3. Select Scatterplot, Simple, then click OK.
4. Enter the variable you want on the left side (y-axis) under “Y variables” and the one you want along the bottom (x-axis) under “X variables”.
5. You can add grid lines by clicking Scale and clicking the Gridlines tab (Use MAJOR ticks).
6. Click OK to display the scatterplot.
Another procedure for generating a scatterplot is to select Stat, Regression, then Fitted Line Plot. We will use this option later when we discuss the topics of correlation and regression (see page 28). For now, we are simply generating the scatterplot to visually explore whether there is an obvious pattern that might reveal some relationship between the two variables.
Time-Series Graph
Time-series data are data that have been collected at different points in time, and Minitab can graph such data so that changing trends become easier to recognize.
Here is the Minitab procedure for generating a time-series graph.
1. Given a collection of time-series data, enter the sequential values in column C1
2. Select the main menu item of Graph. Select the menu item of Time Series Plot, Simple, then click OK. (If you want to show two things at once, you can choose Multiple instead).
3. A dialog box now appears. In the “Series” box you need to put the variables you want to keep track of over time.
4. Click on “Time/Scale.” You need to choose the time scale that you are using. Most of the time, you are looking at Calendar and specifically choosing Year or possibly Day or Month. Then you need to set the Start Values. Click “One set for all variables” and fill in the starting date in the box (such as 1990). In the “Increment” box fill in the length of time between data values (if you gathered every year, the increment is 1; if you gathered every three years, the increment is 3, etc.). (See next page.)
5. Click OK. Click on Labels. Click on the Data Labels tab. Click Use y-value labels.
6. Click OK twice to display the time-series graph.
Boxplot
Here is the Minitab procedure for generating a boxplot.
1. Enter the data in a Minitab column, such as column C1. If the data are already stored in a Minitab worksheet, retrieve the worksheet.
2. Click on the main menu item Graph.
3. Select Boxplot and click on the option of One Y Simple. Click OK.
4. Place your cursor in the “Graph Variables” box and either type in the column label(s) that contain the data you want to use (such as C1) or double click on the column(s) in the left box.
If you have a number of groups that you want to make separate Boxplots for but the numbers are all in one column, instead of “One Y Simple” click on One Y With Groups. Enter the column with the numbers in the “Graph Variables” box and you can use “Categorical Variable” to separate the column. E.g.: separate by car make, or freshman/sophomore/junior/ senior, either of which would be stored in another column.
5. Click on Scale and check the box Transpose value and category scales. This will change the boxplot so it runs horizontally instead of vertically (which is the Minitab default). You can also add grid lines by clicking the Gridlines tab (Use MAJOR ticks).
6. Click OK twice to display the boxplot.
Below is the boxplot for the female pulse rates. Note that Minitab creates a modified boxplot. Any value that it calculates to be an outlier is shown as an asterisk.
Calculating Descriptive Statistics
To display numerical statistics like the Mean, Median, Mode, Standard Deviation, etc., do the following in Minitab:
1. Click Stat and choose Basic Statistics and then Display Descriptive Statistics. You can display the descriptive statistics of more than one variable one by one or all at once. In the Variables box, list the column(s) that you want the descriptive stats for.
2. If you have data that can be separated by classes but the data is all in the same column (like information on GPAs can be separated by classes of freshman, sophomore, etc.) and you want to see the descriptive stats for each, then you enter the variable that separates the classes in the By variables box. (For the previous example, “c1ass” would go in this box.) Otherwise, leave this box blank.
3. Click on Statistics. Here you can choose which descriptive statistics you wish to display. Check / uncheck all boxes as desired. For example, if we do not need SE of Mean, N missing, or N non-missing, then you can uncheck these boxes. Depending on what you are looking at you may wish to check the boxes for Range, Interquartile range, Variance, Coefficient of Variation, Skewness, or N Total.
4. Click OK twice to display the statistics.
The results will be displayed in the Session window.
Again, as mentioned in Step 1, you can enter more than one variable and get all the statistics at once. When you are entering the columns in the “Variables” box, enter as many as you want. Under “Options” you can still choose the individual statistics to report. When you hit OK, the Session window will look as follows:
Descriptive Statistics: Data 1, Data 2
Total
Variable Count Mean SE Mean StDev Variance CoefVar Minimum Q1
Data 1 100 73.24 1.41 14.13 199.62 19.29 31.43 64.72
Data 2 100 125.98 1.80 17.99 323.63 14.28 81.23 116.87
N for
Variable Median Q3 Maximum Range IQR Mode Mode Skewness
Data 1 74.23 82.55 111.48 80.04 17.83 * 0 -0.10
Data 2 126.80 137.12 180.43 99.19 20.24 * 0 -0.04
Variable Kurtosis
Data 1 0.67
Data 2 0.39
Correlation & Regression Analysis
Correlation Coefficient and P-Value
To calculate the correlation coefficient r and the P-value in Minitab, use the following steps:
1. Click Stat and choose Basic Statistics and then Correlation. (See below.)
2. Enter the two variables into the Variables box. (It makes no difference in what order the columns are entered – the value for r will be the same).
3. Click OK to display the results in the Session window.
Both the correlation coefficient (Pearson correlation) and the P-value are displayed. Typical output is as follows:
Correlations: Data 1, Data 2
Pearson correlation of Data 1 and Data 2 = 0.836
P-Value = 0.000
Regression Equation and R-squared
To find the regression equation and R-squared value in Minitab, use the following steps:
1. Click Stat and choose Regression and then Regression. (See below.)
2. In the Response box, enter the variable that you think is dependent on the other. (This is the y -variable.) In the Predictor box, enter the independent variable. (This is the x -variable).
3. Click OK to display the results in the Session window.
A partial sample output looks like this:
Regression Analysis: Data 2 versus Data 1
The regression equation is
Data 2 = 91.9 + 19.3 Data 1
Predictor Coef SE Coef T P
Constant 91.87 65.42 1.40 0.169
Data 1 19.290 2.170 8.89 0.000
S = 156.118 R-Sq = 69.9% R-Sq(adj) = 69.0%
Fitted Line Plot
To draw the scatterplot with the regression equation, use the following steps:
1. Click Stat and choose Regression and then Fitted Line Plot.
2. In the Response (Y) box, enter the dependent (y) variable. In the Predictor (X) box, enter the independent (x) variable.
3. The “Type of Regression Model” should be set to Linear.
4. Click OK to display the Fitted Line Plot.
The output will look like this:
Probability Distributions
Occasionally, a requirement may exist to generate random observations from a specific probability distribution. This manual looks at four distributions: Binomial, Poisson, Uniform, and Normal.
Binomial Probability Distribution
Below are the steps to calculate probability values for a Binomial probability distribution:
1. Enter the values of the random variable for which you are going to calculate the probabilities for in a column of the worksheet. For example, if you were tossing a coin three times and recording the number of heads, your random variable could take on a value of 0, 1, 2, or 3. Therefore, you could enter some (or all) of these values into column C1 (depending on what probabilities you need to find).
2. Select the following: Calc – Probability Distributions – Binomial.
3. Click on Probability. Enter the number of trials, n , and the event probability, p . (The event probability is the probability of getting a success on any one trial.) For example, if we are tossing a coin three times and “heads” is considered a success, then the number of trials is 3 and the event probability is 0.5.
4. Enter the Input column of the values of your random variable (such as C1) from Step 1 and enter an Optional storage (output column) for the probabilities (such as C2).
5. Click OK. The calculated probabilities will be entered in the output column that you selected.
Input : x
Output : P(x)
If you need to add the results, click on Calc and choose Column Statistics. Enter the column you want to sum, then click OK. The result will be displayed in the session window.
Poisson Probability Distribution
Below are the steps to calculate probability values for a Poisson probability distribution:
1. Enter the values for which you are going to calculate the probability distribution in a column of the worksheet.
2. Select the following: Calc – Probability Distributions – Poisson.
3. Click on Probability. Enter the mean.
4. Enter the Input column of the values of your random variable (such as C1) from Step 1 and enter an Optional storage (output column) for the probabilities (such as C2).
5. Click OK. The calculated probabilities will be entered in the output column that you selected.
If you need to add the results, click on Calc and choose Column Statistics. Enter the column you want to sum, then click OK. The result will be displayed in the session window.
Uniform Probability Distribution
Below are the steps to calculate probability values for a Uniform probability distribution:
1. Enter the values for which you are going to calculate the probability distribution in a column of the worksheet.
2. Select the following: Calc – Probability Distributions – Uniform.
3. Click on Cumulative Probability. Enter the lower endpoint and the upper endpoint.
4. Enter the Input column of the values of your random variable (such as C1) from Step 1 and enter an Optional storage (output column) for the probabilities (such as C2).
5. Click OK. The calculated probabilities will be entered in the output column that you selected.
If you are calculating a probability that x is less than some number, the output column is the correct value to use.
If you are calculating a probability that x is greater than some number, you need to subtract the output column from one to get the correct value.
If you are calculating a probability that x is between two values, subtract the two values in the output column so that the answer is positive.
Normal Probability Distribution
Below are the steps to calculate probability values for a Normal probability distribution:
1. Enter the values for which you are going to calculate the probability distribution in a column of the worksheet.
2. Select the following: Calc – Probability Distributions – Normal.
3. Click on Cumulative Probability. Enter the mean and standard deviation.
4. Enter the Input column of the values of your random variable (such as C1) from Step 1 and enter an Optional storage (output column) for the probabilities (such as C2).
5. Click OK. The calculated probabilities will be entered in the output column that you selected.
If you are calculating a probability that x is less than some number, the output column is the correct value to use.
If you are calculating a probability that x is greater than some number, you need to subtract the output column from one to get the correct value.
If you are calculating a probability that x is between two values, subtract the two values in the output column so that the answer is positive.
Alternate method for determining probabilities for a Normal distribution:
1. Select the following: Graph – Probability Distribution Plot – View Probability (last picture). Click OK.
2. Select Normal for the distribution and enter the values for the mean and standard deviation.
3. In the same dialogue box, click on the Shaded Area tab.
4. Define Shaded area by X-value. Choose the correct tail and enter in the x value (or the z score).
5. Click OK. Minitab will display the Normal curve with the correct shaded region and the corresponding probability value.
This alternate method is nice because Minitab not only gives the probability value, but it also shows the calculated area under the curve. It allows you to find the area in either tail or in between two values, and we don’t have to worry about subtracting results like in the previous method.
As an example, IQ scores are normally distributed with a mean of 100 and a standard deviation of 15. Suppose we want to find the probability that a randomly selected person will have an IQ score greater than 110 (i.e., find P(x > 110) ; right tail). We would enter the following in Minitab:
Minitab would then display the following results and we would see that the P(x > 110) = 0.2525
Confidence Intervals
This section provides information on the tools used to make statistical inferences from sample data. The same commands are used for confidence intervals and hypothesis testing but the options selected make the difference.
Confidence interval: population mean, μ
The following procedure is used to create a confidence interval for a population mean, μ.
Select Stat – Basic Statistics. Then choose one of the following:
· 1-Sample Z (1Z) – use 1Z if you know the population standard deviation, σ.
1. If you have original data, enter the column in Samples in Columns. Otherwise click on the bubble for Summarized Data and enter the sample size, mean, and population standard deviation.
2. Click on Options and enter the desired Confidence level as a percent (i.e. 95 for 95%).
3. Click OK twice.
The confidence interval will be displayed in the Session window.
· 1-Sample t (1t) – use 1t if you do not know the population standard deviation, σ.
1. If you have original data, enter the column in Samples in Columns. Otherwise click on the bubble for Summarized Data and enter the sample size, mean, and sample standard deviation.
2. Click on Options and enter the desired Confidence level as a percent (i.e. 95 for 95%).
3. Click OK twice.
The confidence interval will be displayed in the Session window.
· 2-Sample t (2t) – use 2t if you have two unpaired, independent samples.
1. Click Samples in different columns and enter the two columns into the First and Second boxes. Otherwise click on the bubble for Summarized Data and enter the sample sizes, means, and sample standard deviations.
2. Click on Options and enter the desired Confidence level as a percent (i.e. 95 for 95%).
3. Click OK twice.
The confidence interval will be displayed in the Session window.
· Paired t (t-t) – use t-t if you have two paired samples.
1. Click Samples in columns and enter the two columns into the First sample and Second sample boxes.
2. Click on Options and enter the desired Confidence level as a percent (i.e. 95 for 95%).
3. Click OK twice.
The confidence interval will be displayed in the Session window.
Confidence interval: population proportion, p
· 1 Proportion (1P) – use 1P if you have the proportions with only two classifications.
1. Click on Summarized data.
2. Enter the number of events (x) and the number of trials (n).
3. Click on Options and enter the desired Confidence level as a percent (i.e. 95 for 95%).
4. Click OK twice.
The confidence interval will be displayed in the Session window.
Note: if you have the trials and percentage, you must multiply the trials by the percent to determine the number of events (successes). For example, if you had a sample of 1064 adults and 53% believe in global warming, then the number that believe in global warming would be 0.53(1064) = 563.92 or 564. (Here, you would enter 564 for the number of events and 1064 for the number of trials.)
· 2 Proportions (2P) – use 2P if you have two independent populations with two classifications.
1. Click on Summarized data.
2. Enter the number of events and the number of trials for the two independent populations.
3. Click on Options and enter the desired Confidence level as a percent. (i.e. 95 for 95%).
4. Click OK twice.
The confidence interval will be displayed in the Session window.
Hypothesis Testing
This section deals with situations in which a claim is made about a population parameter. There will be a null hypothesis (H0) and an alternative hypothesis (H1 or HA). These hypotheses should be stated prior to selecting the command.
Hypothesis Testing: population mean, μ
Select Stat – Basic Statistics. Then choose one of the following:
· 1-Sample Z (1Z) – use 1Z if you know the population standard deviation, σ.
1. If you have original data, enter the column in Samples in Columns. Otherwise click on the bubble for Summarized Data and enter the sample size, mean, and population standard deviation.
2. Click Perform Hypothesis test and enter the hypothesized mean (the value in the null hypothesis, H0).
3. Click on Options and enter the desired Confidence level as a percent (i.e. Enter 95 for a hypothesis test with a 0.05 significance level.)
4. Change the Alternative to match the symbol in HA, the alternative hypothesis.
5. Click OK twice.
The p-value will be displayed in the Session window.
· 1-Sample t (1t) – use 1t if you do not know the population standard deviation, σ.
1. If you have original data, enter the column in Samples in Columns. Otherwise click on the bubble for Summarized Data and enter the sample size, mean, and sample standard deviation.
2. Click Perform Hypothesis test and enter the hypothesized mean (the value in the null hypothesis, H0).
3. Click on Options and enter the desired Confidence level as a percent (i.e. Enter 95 for a hypothesis test with a 0.05 significance level.)
4. Change the Alternative to match the symbol in HA, the alternative hypothesis.
5. Click OK twice.
The p-value will be displayed in the Session window.
· 2-Sample t (2t) – use 2t if you have two unpaired, independent samples.
1. Click Samples in different columns and enter the two columns into the First and Second boxes. Otherwise click on the bubble for Summarized Data and enter the sample sizes, means, and sample standard deviations.
2. Do Not check the box labeled “Assume equal variances”.
3. Click on Options and enter the desired Confidence level as a percent (i.e. Enter 95 for a hypothesis test with a 0.05 significance level.)
4. Enter 0 for the Test mean, then select the Alternative to match the symbol in HA, the alternative hypothesis.
5. Click OK twice.
The p-value will be displayed in the Session window.
· Paired t (t-t) – use t-t if you have two paired samples.
1. Click Samples in columns and enter the two columns into the First sample and Second sample boxes.
2. Click on Options and enter the desired Confidence level as a percent (i.e. enter 95 for a hypothesis test with a 0.05 significance level.)
3. Enter 0 for the Test mean, then select the Alternative to match the symbol in HA, the alternative hypothesis.
4. Click OK twice.
The p-value will be displayed in the Session window.
Hypothesis Testing: population proportion, p
· 1 Proportion (1P) – use 1P if you have the proportions with only two classifications.
1. Click on Summarized data. Enter the number of events (x) and the number of trials (n).
2. Click Perform Hypothesis test and enter the hypothesized proportion (as a decimal).
3. Click on Options and enter the desired Confidence level as a percent (i.e. Enter 95 for a hypothesis test with a 0.05 significance level.)
4. Change the Alternative to match the symbol in HA, the alternative hypothesis.
5. Click OK twice.
The p-value will be displayed in the Session window.
· 2 Proportions (2P) – use 2P if you have two independent populations with two classifications.
1. Click on Summarized data. Enter the number of events and the number of trials for the two independent populations.
2. Click on Options and enter the desired Confidence level as a percent. (i.e. Enter 95 for a hypothesis test with a 0.05 significance level.)
3. Enter 0 for the Test difference, then select the Alternative to match the symbol in HA, the alternative hypothesis.
4. Click on the box to use the pooled estimate of p for the test.
5. Click OK twice.
The p-value will be displayed in the Session window.
Minitab Guide Fall 2011 – Updated Spring 2015 5
12011010090807060
14
12
10
8
6
4
2
0
Pulse rates
F
r
e
q
u
e
n
c
y
Histogram of Pulse Rates
12511510595857565
40
30
20
10
0
Pulse rates
P
e
r
c
e
n
t
Histogram of Pulse rates
13012011010090807060
Pulse Rates (bpm)
Boxplot of Female Pulse Rates
7
0
6
0
5
0
4
0
3
0
2
0
1
0
1
4
0
0
1
2
0
0
1
0
0
0
8
0
0
6
0
0
4
0
0
2
0
0
D
a
t
a
1
D
a
t
a
2
S
1
5
6
.
1
1
8
R
-
S
q
6
9
.
9
%
R
-
S
q
(
a
d
j
)
6
9
.
0
%
F
i
t
t
e
d
L
i
n
e
P
l
o
t
D
a
t
a
2
=
9
1
.
8
7
+
1
9
.
2
9
D
a
t
a
1
0.030
0.025
0.020
0.015
0.010
0.005
0.000
X
D
e
n
s
i
t
y
110
0.2525
100
Distribution Plot
Normal, Mean=100, StDev=15