Presentation is loading. Please wait.

Presentation is loading. Please wait.

AP Statistics Understanding Randomness Chapter 11.

Similar presentations


Presentation on theme: "AP Statistics Understanding Randomness Chapter 11."— Presentation transcript:

1 AP Statistics Understanding Randomness Chapter 11

2 Objectives Random Generating random numbers Simulation Simulation component Trial Response variable

3 Why Be Random? What is it about chance outcomes being random that makes random selection seem fair? Two things: –Nobody can guess the outcome before it happens. –When we want things to be fair, usually some underlying set of outcomes will be equally likely (although in many games some combinations of outcomes are more likely than others).

4 Why Be Random? Example: –Pick “heads” or “tails.” –Flip a fair coin. Does the outcome match your choice? Did you know before flipping the coin whether or not it would match? You can’t predict how a fair coin will land on any single toss, but you’re pretty confident that if you flipped it a thousands of times you’d see about 50% heads.

5 Why Be Random? Randomness is not always what we might think of as “at random.” An outcome is random if we know the possible values it can have, but not which particular value it takes. Random outcomes have a lot of structure, especially when viewed in the long run. Truly random values are surprisingly hard to get.

6 Why Be Random? Statisticians don’t think of randomness as the annoying tendency of things to be unpredictable or haphazard. Statisticians use randomness as a tool. But, truly random values are surprisingly hard to get…

7 It’s Not Easy Being Random

8 It’s surprisingly difficult to generate random values even when they’re equally likely. Computers have become a popular way to generate random numbers. –Even though they often do much better than humans, computers can’t generate truly random numbers either. –Since computers follow programs, the “random” numbers we get from computers are really pseudorandom. –Fortunately, pseudorandom values are good enough for most purposes.

9 Does shuffling cards make the deck random? It depends on the number of shuffles. How many times should you shuffle cards to make the deck random? A surprising fact was discovered by statisticians Persi Diaconis, Ronald Graham, and W.M. Kantor. It takes seven shuffles. Fewer than seven leaves order in the deck, but after that, more shuffling does little good.

10 It’s Not Easy Being Random There are ways to generate random numbers so that they are both equally likely and truly random. The best ways we know to generate data that give a fair and accurate picture of the world rely on randomness, and the ways in which we draw conclusions from those data depend on the randomness, too.

11 Three Methods of Determining the Chance of an Event Occurring 1.Try to estimate the likelihood of a result of interest by actually carrying out the experiment many times and calculating the result’s relative frequency. –Drawbacks – slow, costly, often impractical or logistically difficult. 2.Develop a probability model and use it to calculate a theoretical answer. (Later Chapters) 3.Start with a model that, in some fashion, reflects the truth about the experiment, and then develop a procedure for imitating-or simulating-a number of repetitions of the experiment.

12 Practical Randomness Suppose a cereal manufacturer puts pictures of athletes on cards in boxes of cereal to boost sales. The manufacturer announces that 20% of the boxes contain a picture of Tiger Woods, 30% a picture of David Beckham, and the rest a picture of Serena Williams. You want all three pictures. How many boxes of cereal do you expect to have to buy in order to get the complete set? How can we answer questions like this? We need an imitation of a real process so we can manipulate and control it. In short, we are going to simulate reality.

13 Simulation Definition – The imitation of chance behavior, based on a model that accurately reflects the experiment under consideration. Simulation is a powerful tool for gaining insight into events whose outcomes are random.

14 A Simulation The sequence of events we want to investigate is called a trial. The basic building block of a simulation is called a component. –Trials usually involve several components. After the trial, we record what happened—our response variable. Use random digits from a table, graphing calculator or computer software to simulate many repetitions.

15 Simulation Modeling the Outcomes –Assign digits to represent outcomes so the digits will occur with the same long-term relative frequency as the actual outcomes. Examples: –Choose a person at random from a group of which 70% are employed. One digit simulates one person 0,1,2,3,4,5,6 – employed 7,8,9 - unemployed

16 Simulation Examples: –Choose one person at random from a group of which 73% are employed. Now two digits simulate one person 00,01,02,03,…,72 – employed 73,74,75,78,…,99 - unemployed –Choose one person at random from a group of which 50% are employed, 20% are unemployed, and 30% are not in the labor force. One digit simulates one person 0,1,2,3,4 – employed 5,6 – unemployed 7,8,9 – not in labor force

17 Simulation Your Turn: –Choose a frozen yogurt flavor. Orders of frozen yogurt flavors (based on sales) have the following relative frequencies: 38% chocolate, 42% vanilla, and 20% strawberry. Model the outcomes.

18 18 Random Digits Table There many different random number tables. One example is given to the right. Random Digits Table Line 1011922395034057562871396409125314254482853 1027367647150994000192727754426488242536290 1034546771709775580009532863294858222690056 1045271138889930746022740011858484876752573 1059559294007699719148160779537911729759335 1066841735013155297276585089570675021147487 1078273957890208074751181676553009438314893 1086094072024178682494361790906568796418883 1093600919365154123963885453468168348541979 1103844848789183382469739364420067668808708 1118148669487605130929700412712382764939950 1125963688804046347119719352730898489845785 1136256870206403250369971080225531148611776 1144514932992757306628003819562020293870915 1156104177684943222470973698145263189332592 1161445926056314248037165103622535049061181 1173816798532621837063223417261854144875532 1187319032533044702966984407907856595686382 1199585707118876649209958806669799862484826 1203547655972394216585004266354354374211937 1217148709984290771486361683470526222451025 1221387381598950529090873592751868713695761 1235458081507271025602755892330634184281868 1247103509001433674949772719967582761191596 1259674612149378237186818442351196210339244 1269692719931360897419277567887414840941903 1274390999477253306435940085169258511736071 1281568914227065651437413352493678198287209 1293675958984682882291318638543030079508727 1306905164817871740951784534064898720197245 1310500716632811941487304197855764519596565 1326873255259842920879643165937393168597150 1334574041807655613330207051936231813209547 1342781678416183292133735213377410431268508 1356692555658391007845811206198768715131260 1360842144753773772874475592085637914092454 1375364566812614214783612609153739848114592 1386683168908407722155847781335867917706928 1395558899404707084109843563569344839451719 1401297513258130484514472321819400036002428 1419676735964238229601294591651945084253372 1427282950232978926340877919445752487004178 1438856542628177974937661762169538860412724 1446296488145830836945346109595056968000900 1451968712633578579580609931021504316358636 1463760959057669678340160705023849059793600 1475497386278887377435147500845521990967181 1480069405977196646544120903623712272553340 1497154605233539466874372460276014540388692 1500751188915412671685384569793673233703316

19 19 How to use a Random Digit Table? Decide on the minimum number of digits. Start on any line in the table or the assigned line. The sequence of reading the numbers (the number of digits, (group of digits – 1 digit, 2 digits, 3 digits …) should be maintained until the desired number of random numbers is attained. If a particular number is not included in your range of number values being used, skip it and go the next group of digits. Keep selecting the numbers, if you get to the end of a line just continue on the next line, until you have the required number of random numbers.

20 20 Example Suppose we want to select 5 random numbers from 1 to 8000. Using the random number table given below 8442 5653 8775 1891 7666 6483 9711 6941 8092 3875 4200 6543 9063 1003 8754 2564 8890 4195 8888 6490 3476 We will start at the top left hand corner and read across. We need to use four digit groups at a time as there is a minimum of four digits in our number range 1 – 8000.

21 21 Example (continued) 8442 5653 8775 1891 7666 6483 9711 6941 8092 3875 4200 6543 9063 1003 8754 2564 8890 4195 8888 6490 3476 Let us start. The first group of 4 digits is 8442. 8442 not in our range-ignore 5653-use -1 8775-ignore 1891-use -2

22 22 Example (continued) 8442 5653 8775 1891 7666 6483 9711 6941 8092 3875 4200 6543 9063 1003 8754 2564 8890 4195 8888 6490 3476 7666- use -3 6483- use -4 9711-ignore 6941-use -5

23 23 Example (continued) So our 5 random numbers from 1 to 8000 consists of; 5653,1891,6483,7666, and 6941.

24 Simulation Step-By-Step 1.Identify the component to be repeated. 2.Explain how you will model the outcome (assign digits). 3.Explain how you will simulate the trial. 4.State clearly what the response variable is. 5.Run several trials. 6.Analyze the response variable. 7.State your conclusion (in the context of the problem, as always).

25 Simulation Example Suppose a cereal manufacturer puts pictures of famous athletes on cards in boxes of cereal in the hope of boosting sales. The manufacturer announces that 20% of the boxes contain a picture of Tiger woods, 30% a picture of Lance Armstrong, and the rest a picture of Serena Williams. You want all three pictures. How many boxes of cereal do you expect to have to buy in order to get the complete set?

26 Simulation Example 1.Identify the component to be repeated. –The selection of a cereal box. 2.Explain how you will model the outcome (assign digits). –0,1 – Woods –2,3,4 – Armstrong –5,6,7,8,9 – Williams

27 Simulation Example 3.Explain how you will simulate the trial. –A trial is the sequence of events that we are pretending will take place. –In this case we want to pretend to open cereal boxes until we have one of each picture. –So one trial of the simulation is the number of boxes opened until we’ve gotten all three pictures.

28 Simulation Example 4.State clearly what the response variable is. –What are we interested in? –We want to know how many boxes it takes to get all three pictures. –This is the response variable. 5.Run several trials. –The more trails you run the more accurate your result.

29 Simulation Example Running Trials (start line 130 on Random Digit Table) Trial #Outcomes# Boxes 1 6905164 Williams, Williams, Woods, Williams, 7 Woods, Williams, Armstrong 2 81787174 Williams, Woods, Williams, Williams, 8 Williams, Woods, Williams, Armstrong 3 0951784 Woods, Williams, Williams, Woods, 7 Williams, Williams, Armstrong

30 Simulation Example Trial #Outcomes# Boxes 4 5340 Williams, Armstrong, Armstrong, Woods 4 5 64898720 Williams, Armstrong, Williams, Williams 8 Williams, Williams, Armstrong, Woods 6 1972 Woods, Williams, Williams, Armstrong 4 Create a chart to keep track of the results.

31 Simulation Example 6.Analyze the response variable. –We wanted to know how many boxes we might expect to buy, so we calculate the average number of boxes per trail. –Average (7+8+7+4+8+4)/6 = 6.3 7.State your conclusion (in the context of the problem, as always). –Based on our simulation, we estimate that customers who want the complete set of sports star pictures will buy an average of 6.3 boxes.

32 Simulation Problem 57 students participated in a lottery for a particularly desirable dorm room – a triple with a fireplace and private bath in the tower. 20 of the participants were members of the same varsity sports team. When all 3 winners were members of the team, the other students cried foul. Use a simulation to determine whether an all-team outcome could reasonably be expected to happen if everyone had a fair shot at the room.

33 Simulation Problem 1.Identify the component to be repeated. –Selection of a student 2.Explain how you will model the outcome (assign digits). –Look at two digit random numbers –00-19 represent the 20 varsity team members –20-56 represent the other 37 students –57-99 skip as unused numbers

34 Simulation Problem 3.Explain how you will simulate the trial. –Each trial consists of picking pairs of random digits as V (varsity) or N (non-varsity) until 3 people are chosen, ignoring out-of-range or repeated numbers (X). 4.State clearly what the response variable is. –Whether are not all the selected students are on the varsity team.

35 Simulation Problem 5.Run several trials. (use line 101) Trial #OutcomesAll Varsity 119V,22N,39Nno 250N,34N,05Vno 375X,62X,87X,13V,96Xno 40N, 91X,25N 431N,42N,54Nno 548N,28N,53Nno

36 Continued Trials Trial #OutcomesAll Varsity 673X,67X,64X,71X,50Nno 99X,40N,00V 719V,27N,27X,75X,44Nno 826N,48N,82X,42Nno 953N,62X,90X,45N,46Nno 1077X,17V,09V,77X,55Nno 1180X,00V,95X,32N,86X,no 32N

37 Continued Trials Trial #OutcomesAll Varsity 1294X,85X,82X,22N,69Xno 00V,56N 1352N,71X,13V,88X,89Xno 93X,07V 1446N,02V,27Nno 1540N,01V,18Vno 1658X,48N,48N,76X,75Xno 25N

38 Continued Trials Trial #OutcomesAll Varsity 1773X,95X,59X,29N,40N no 07V 1869X,97X,19V,14V,81Xno 60X,77X,95X,37N 1991X,17V,29N,75X,93Xno 35N 2068X,41N,73X,50N,13Vno

39 Simulation Problem 6.Analyze the response variable. –“all varsity” occurred zero times out of 20 trials or 0% of the time. 7.State your conclusion (in the context of the problem, as always). –In our simulation of “fair” room draws the three people chosen were all varsity team members 0% of the time (for 20 draws). It is not particularly likely a fair draw would pick all varsity team members and we should be suspicious of the stated outcome.

40 Calculator Simulation Instead of using coins, dice, cards, or tables of random numbers, you can use the TI-83/84 calculator for simulations. There are several random number generators offered in the MATH PRB menu. –randInt(0,1) randomly chooses a 0 or a 1. Effective simulation of a coin toss. –randInt(1,6) produces a random integer from 1 to 6, a good way to simulate rolling a die. –randInt(1,6,2) simulates rolling 2 dice. To do several rolls in a row, just hit ENTER repeatedly. –randInt(0,56,3) produces 3 random integers between 0 & 56, a good way to simulate the dorm room lottery.

41 Calculator Simulation To set up the calculator so everyone gets the same random digits (like using the same line on a random digit table), you must store the same value in the rand function as shown below. To access rand function; MATH/PRB/rand To input; type 124, then “STO” key, “rand”, and ENTER. (124→rand)

42 Calculator Simulation Problem A basketball player makes 70% of her free throws in a long season. In a tournament game she shoots 5 free throws late in the game and misses 3 of them. The fans think she was nervous, but the misses may be due to chance. Simulate an experiment to determine which it is?

43 Calculator Simulation Problem 1.Identify the component to be repeated. –Shooting free throws 2.Explain how you will model the outcome (assign digits). –Each single digit represents a free throw –0 – 6 represents a made free throw –7-9 represents a missed free throw 3.Explain how you will simulate the trial. –Each trial will consist of 5 shots ( 5 random numbers from 0 to 9) to determine if she has 3 or more misses.

44 Calculator Simulation Problem 4.State clearly what the response variable is. –Whether she has 3 or more misses. 5.Run several trials. (124 rand) –Run 50 trials and count the number of times she has 3 or more misses. –randInt(0,9,5) – 50 times 6.Analyze the response variable. –3 or more misses occurred 11 times out of 50 trials.

45 Calculator Simulation Problem 7.State your conclusion (in the context of the problem, as always). –In our simulation she missed 3 or more free throws only 11 out of 50 times or 22%. –We therefore conclude she choked.

46 Simulation Cautions 1.Don’t overstate your case. –In some sense a simulation is always wrong. After all, it’s not the real thing. We didn’t buy any cereal, or run a room draw. So beware of confusing what really happens with what a simulation suggests might happen. Always be sure to indicate that future results will not match your simulated results exactly.

47 Simulation Cautions 2.Model the outcome chances accurately. A common mistake in constructing a simulation is to adopt a strategy that may appear to produce the right kind of results, but that does not accurately model the situation. If your simulation overlooks important aspects of the real situation, your model will not be accurate.

48 Simulation Cautions 3.Run enough trials. Simulation is cheap and fairly easy to do. Don’t try to draw conclusions based on 5 or 10 trials (even though we did for illustration purposes here). The larger the number of trials the better.

49 What have we learned? How to harness the power of randomness. A simulation model can help us investigate a question when we can’t (or don’t want to) collect data, and a mathematical answer is hard to calculate. How to base our simulation on random values generated by a computer, generated by a randomizing device, or found on the Internet. Simulations can provide us with useful insights about the real world.


Download ppt "AP Statistics Understanding Randomness Chapter 11."

Similar presentations


Ads by Google