Math 362 - Computer Lab #1 - Spring 2003
Introduction
to Probability Theory
Computer Lab 1: MINITAB
We will start learning how to use MINITAB by simulating the tossing of 10 fair coins.
We will show how MINITAB can be used to do this repeatedly.
- Open MINITAB
- In Windows, from the taskbar, choose
- Start -> Programs -> Minitab 13 for Windows -> MINITAB
- Simulate 10 tossings of a coin
To this end, we will generate 10 random numbers, either 0 and 1.
Each number can be associated with a symbol, T for tails if the number is 0
and H for heads if the number is 1.
- Create a collection of 10 random numbers
- In the Calc menu, select Random Data -> Bernoulli...
- Fill in the appropriate fields, in order to generate 10 rows of data,
to be stored in column C1. Each row will contain a number
either 0 or 1. (What should the probability of success be?)
- Assign a symbol to each number
- In the Manip menu, select Code -> Numeric to Text...
- Then, code data from Column C1 into Column C2, according to the
following rule
- Original values 0 become T
- Original values 1 become H
- Count the number of heads and tails
You can count by hand since there are only 10 entries in Column C2.
You can also use MINITAB:
- In the Stat menu, choose Tables -> Tally...
- Enter C2 in the Variables field and click OK.
- The result is displayed in the Session window and should of course agree
with your hand count. You can also display the percentage of heads and tails by
checking Percents as well as Counts under Display in the
Tally... dialog box.
- Plot a histogram of the data
- In the Graph menu, choose Histograms...
- Enter C1 in the Variables field and click OK
- Repeat this operation 10 times
- In the Calc menu, select Random Data -> Bernoulli...
- Fill in the appropriate fields, in order to generate 10 rows of data,
to be stored in column C3-C12.
- In the Stat menu, choose Tables -> Tally...
- Enter C3-C12 in the Variables field and click OK
- Using 0 to code for T and 1 to code for H, record the number of heads and
tails obtained in each case.
Run # | Number of Heads | Number of Tails |
1 | ... | ... |
2 | ... | ... |
3 | ... | ... |
4 | ... | ... |
5 | ... | ... |
6 | ... | ... |
7 | ... | ... |
8 | ... | ... |
9 | ... | ... |
10 | ... | ... |
- Can you use the outcome of any of these 10 experiments to determine the probability
of obtaining a head or a tail? Why or why not?
- How could you modify the above to obtain a more accurate estimate of each probability?
- Use MINITAB to simulate the drawing of objects of different
colors from a bag, as we did in Lab #1
- Encode the distribution.
- In C13 enter 0,1,2. Let 0 code for pink, 1 code for green and 2 code for white.
- In C14 enter 0.5 in row 1, 0.3 in row 2, and 0.2 in
row 3.
- Simulate 10 times the experiment of taking
1000 drawings from a bag which contains 50% pink tiles, 30% green tiles and 20%
white tiles.
- In the Calc menu, select Random Data -> Discrete...
- Generate 1000 rows of data, store in columns C15-C24.
- Take values in C13 and probabilities in C14.
- Tally your results.
Back to Math 362