220 likes | 344 Views
Lecture 7. Reminder: Paper 1. Select an area of human endeavor and write a 5 page paper on how statistics influenced it. D ue a week from Tuesday, 9/23. Make sure you clearly reference your sources (including websites). Probability models. Probability models
E N D
Reminder: Paper 1 • Select an area of human endeavor and write a 5 page paper on how statistics influenced it. • Due a week from Tuesday, 9/23. • Make sure you clearly reference your sources (including websites)
Probability models • Probability models • sample space (set of possible outomes) • events • probabilities • Rules for probabilities • Assigning probabilities when the sample space is finite • Assigning probabilities when all outcomes are equally likely • Independence and the multiplication rule
Probability models Definition: A probability model for a random phenomenon consists of • The set of all possible outcomes of the phenomenon. This set is called the sample spaceand denoted S. • An assignment of probabilities to events, which are subsets of S. The probability of event A is denoted P(A).
Probability models:Assignment of probabilities to events • Assignment of probabilities to events can be done in any of several ways: • If S is a finite set, assign probabilities to the individual outcomes; then probability of an event is the sum of the probabilities of the outcomes in it. • As in Examples 1, 2, and 4 above. • If S is an infinite set of real numbers, such as the set of all real numbers or all positive numbers, assign probabilities to intervals in some way. • E.g., in Example 3 above. By standardizing and using normal table, we could assign probability to the interval of scores less than 115. • Other methods in other kinds of models • In any case, the probabilities must be assigned in a way that follows four basic rules. • These rules are necessary because proportions follow them. The rules:
Probability models:Rules for assignment of probabilities to events Rule 1: Any probability must be a number between 0 and 1. This is because the proportion of times an event occurs is always between 0 and 1. Rule 2: The probability of the set of all possible outcomes together must total 1. This is because the proportions of times that all outcomes occur must add to 1 (= 100%). Rule 3: If two events have no outcomes in common, then the probability that one or the other occurs must be the sum of their probabilities. They can never occur together, so the proportion of times that one or the other occurs must be the sum of their individual proportions. Rule 4: The probability that an event does not occur must be 1 minus the probability that it does occur. The proportion of times it doesn’t occur, plus the proportion of times it does occur, must total 1.
Probability models:Rules for assignment of probabilities to events The four rules, restated briefly: P(A) denotes the probability of event A in sample space S. Rule 1: For any event A, 0 ≤ P(A) ≤ 1. Rule 2: P(S) = 1. Rule 3: If events A and B are disjoint (have no outcomes in common, i.e. cannot occur together), then P(A or B) = P(A) + P(B). Rule 4: If Acdenotes the complement of A (the event that A does not occur), then P(Ac) = 1 – P(A).
Probability models: Assigning probabilities when the sample space is finite • If the set of possible outcomes is finite: • Assign a probability between 0 and 1 to each individual outcome, making sure that the assigned probabilities add to 1. • To make the model match reality, make the assigned probabilities equal to the expected long-run proportions of times the outcomes occur. • Then the probability of any event is the sum of the probabilities assigned to its outcomes. • The four rules are then automatically satisfied, and we can use Rules 3 and 4 to help find probabilities. Examples
ExampleAssigning probabilities when the sample space is finite For numbers in tables of financial, demographic, and other data, the first digits are not equally likely! Their proportions typically are close to Benford’s Law:
Benford’s Law is approximately valid forpopulations of NC counties in 2010
Original scale Log scale
R code N=100000 maxT=100 x=maxT*runif(N) y=10^x firstdigit=floor(y/10^floor(log(y,10))) table(firstdigit)/N
Homework (due a week from Thursday) • Select your favorite list of numbers. (Must contain 100+ items) • Does it follow Benford’s law? Explain • (Make a table computed from your data and compare to the Benford’s law table.)
Probability models: Example 6 Assigning probabilities when the sample space is finite Roll 3 fair dice, count the number of 6’s that come up. Sample space is S = {0,1,2,3}. We’ll see later why the following is an appropriate assignment of probabilities to the four outcomes. • Probability that there are 2 or 3 sixes: • Probability that there is at least one six:
Probability models:Finite sample spaces with equally likely outcomes • If we can assume that all possible outcomes are equally likely, then the assignment of probabilities to individual outcomes is easy: • If the sample space S has k outcomes in all, then each must have probability 1/k. • So in the case of equally likely outcomes, if A is any event, then P(A) = (number of outcomes in A) / k .
Probability models: ExampleFinite sample spaces with equally likely outcomes SRS of size 2 from a set of 5 people Label the people 1,2,3,4,5. S has 10 equally likely members: 12, 13, 14, 15, 23, 24, 25, 34, 35, 45 (Why can we assume they are equally likely?) So each is assigned a probability of _____. Event A = “2 is chosen but 3 is not.” P(A) = _____ Event B = “either 2 or 3 or both is chosen.” P(B) = _____
Recap • Probability models where S is a finite set of outcomes: • Assign a probability to each outcome in S, making sure they’re all ≥ 0 and add to 1. • It’s the job of the person setting up the model to assure that the assignment applies to the situation at hand. • That is, that the probabilities represent expected long-run proportions. • Then the probability of any event A (subset of S)is the sum of the probabilities assigned to the outcomes in A. • A simple special case: If we can assume all outcomes are equally likely, then each has probability 1/k where k is the number of outcomes in S. • Probability models where S is an interval of real numbers: • Use some rule to assign probabilities to intervals in S (rather than to individual outcomes). • Most important example: normal probabilities, found from Table A. • In any model, use Rules 3 and 4 to find • P(A or B) when A and B are disjoint • P(Ac) for any A
Independence and the multiplication rule Events A and B are independent if knowing that one occurs does not change the probability that the other occurs. Rule 5: If events A and B are independent, then P(A and B) = P(A)P(B).
Independence and the multiplication rule: Example 1 Toss a coin twice and let A = “heads on the first toss,” B = “heads on the second toss.” These are independent, because we assume the outcome of one toss can’t affect the outcome of another toss. (If this assumption needs verification, we could test it with many repetitions of the two-toss experiment.) So, since we know P(A) = 1/2 and P(B) = 1/2,Rule 5 says that P(A and B) = (1/2)(1/2) = 1/4. Exercise: In the sample space for this experiment, identify the three events (1) A; (2) B; (3) A and B; and check that their probabilities are as given above.
Independence and the multiplication rule: Example 2 Take a SRS of size 2 from a group of 5 people. Number the people 1,2,3,4,5. Then the sample space S contains 10 outcomes: 12, 13, , , , , , , , . Let A = “Person #1 is chosen,” B = “Person #2 is chosen.” These are not independent. Knowing that #1 is chosen decreases the chance that #2is chosen. Exercise: In the sample space, identify the three events (1) A, (2) B, (3) A and B. Find their probabilities and verify that P(A and B) does not equal P(A)P(B).
Independence and the multiplication rule: Example 3 Draw 2 cards at random from a standard deck, but replace the first card and reshuffle before drawing the second. What’s the probability that they’re both hearts? • Standard deck has 52 cards; 13 are hearts. Let A = “1st card is a heart” and B = “2nd card is a heart.” We want P(A and B). P(A) = _______ and P(B) = _______. So P(A and B) = ________. How would the answer change if we did not return the first card back?
4.2 Probability models:ndependence and the multiplication rule Independence and the multiplication rule: Example 4 From a very large population in which 40% identify themselves as Democrats, take a SRS of size 3. What’s the probability that they’re all Democrats? Let A = “First one chosen is a Democrat,” B = “second one is a Democrat,” and C = “third one is a Democrat”. They’re not really independent. For example, if we know A occurred, then B and C are very slightly less likely than if A had not occurred. But because the population is so large, it is nearlytrue (and we can safely assume) that • They’re independent, and • The probability of each is .40. So the probability that they’re all Democrats is ______