UCLA STAT 110 A Applied Probability & Statistics For .

Transcription

UCLA STAT 110 AApplied Probability & Statistics forChapter 2: ProbabilityEngineerszInstructor:zWhere do probabilities come from?Ivo Dinov,Asst. Prof. In Statistics and NeurologyzTeachingAssistant:Maria Chang, UCLA StatisticsUniversity of California, Los Angeles, Spring 2003zSimple probability modelszprobability ruleszConditional probabilityzStatistical independencehttp://www.stat.ucla.edu/ dinov/STAT 110A, UCLA, Ivo DinovSlide 1STAT 110A, UCLA, Ivo DinovLet's Make a Deal Paradox –aka, Monty Hall 3-door problemz This paradox is related to a popular television showin the 1970's. In the show, a contestant was given achoice of three doors/cards of which one contained aprize (diamond). The other two doors contained gaggifts like a chicken or a donkey (clubs).Slide 2Let's Make a Deal Paradox.z After the contestant chose an initial door, the host ofthe show then revealed an empty door among the twounchosen doors, and asks the contestant if he or shewould like to switch to the other unchosen door. Thequestion is should the contestant switch. Do the oddsof winning increase by switching to the remainingdoor?1.PickOnecard2.Show oneClub Card3. Change1st pick?Slide 3STAT 110A, UCLA, Ivo DinovLet's Make a Deal Paradox.z The intuition of most people tells them that each ofthe doors, the chosen door and the unchosen door, areequally likely to contain the prize so that there is a50-50 chance of winning with either selection? This,however, is not the case.z The probability of winning by using the switchingtechnique is 2/3, while the odds of winning by notswitching is 1/3. The easiest way to explain this is asfollows:Slide 5STAT 110A, UCLA, Ivo DinovSlide 4STAT 110A, UCLA, Ivo DinovLet's Make a Deal Paradox.z The probability of picking the wrong door in theinitial stage of the game is 2/3.z If the contestant picks the wrong door initially, thehost must reveal the remaining empty door in thesecond stage of the game. Thus, if the contestantswitches after picking the wrong door initially, thecontestant will win the prize.z The probability of winning by switching then reducesto the probability of picking the wrong door in theinitial stage which is clearly 2/3.Slide 6STAT 110A, UCLA, Ivo Dinov1

Definitions Long run behavior of coin tossing0.6z The law of averages about the behavior of coin tosses– the relative proportion (relative frequency) of heads-to-tails0.5in a coin toss experiment becomes more and more stable asthe number of tosses increases. The law of averages applies torelative frequencies not absolute counts of #H and #T.z Two widely held misconceptions about what the lawof averages about coin tosses:0.410Figure 4.1.1121010Number of tosses3104Proportion of heads versus number of tossesfor John Kerrich's coin tossing experiment. Differences between the actual numbers of heads & tailsbecomes more and more variable with increase of thenumber of tosses – a seq. of 10 heads doesn’t increase thechance of a tail on the next trial. Coin toss results are fair, but behavior is still unpredictable.From Chance Encounters by C.J. Wild and G.A.F. Seber, John Wiley & Sons, 2000.Slide 7Slide 8STAT 110A, UCLA, Ivo DinovCoin Toss Modelsz Is the coin tossing model adequate for describing thesex order of children in families? This is a rough model which is not exact. In most countriesrates of B/G is different; form 48% 52%, usually. Birthrates of boys in some places are higher than girls, however,female population seems to be about 51%. Independence, if a second child is born the chance it hasthe same gender (as the first child) is slightly bigger.STAT 110A, UCLA, Ivo DinovData from a “random” draw366 cylinders (for each day in the year) for theUS Vietnam war draft. The N-th drawn number,corresp. to one B-day, indicating order of drafting.220200180So, people born later inthe year tend to havelower lottery numbersand a bigger chance ofactually being DecMonth of the yearFigure 4.3.1Average lottery numbers by month.Replotted from data in Fienberg [1971].From Chance Encounters by C.J. Wild and G.A.F. Seber, John Wiley & Sons, 2000.Slide 9STAT 110A, UCLA, Ivo DinovTypes of Probabilityz Probability models have two essential components (sample space,the space of all possible outcomes from an experiment; and a listof probabilities for each event in the sample space). Where do theoutcomes and the probabilities come from?z Probabilities from models – say mathematical/physical descriptionof the sample space and the chance of each event. Construct a fair die tossinggame.z Probabilities from data – data observations determine ourprobability distribution. Say we toss a coin 100 times and theobserved Head/Tail counts are used as probabilities.z Subjective Probabilities – combining data and psychologicalfactors to design a reasonable probability table (e.g., gambling,stock market).Slide 11STAT 110A, UCLA, Ivo DinovSlide 10STAT 110A, UCLA, Ivo DinovSample Spaces and Probabilitiesz When the relative frequency of an event in the past is used toestimate the probability that it will occur in the future, whatassumption is being made?T The underlying process is stable over time;T Our relative frequencies must be taken from large numbers for us tohave confidence in them as probabilities.z All statisticians agree about how probabilities are to becombined and manipulated (in math terms), however, not allagree what probabilities should be associated with a particularreal-world event.z When a weather forecaster says that there is a 70% chance ofrain tomorrow, what do you think this statement means? (Basedon our past knowledge, according to the barometric pressure, temperature,etc. of the conditions we expect tomorrow, 70% of the time it did rainunder such conditions.)Slide 12STAT 110A, UCLA, Ivo Dinov2

The complement of an eventSample spaces and eventsz A sample space, S, for a random experiment is the setof all possible outcomes of the experiment.z The complement of an event A, denoted A ,occurs if and only if A does not occur.z An event is a collection of outcomes.Sz An event occurs if any outcome making up that eventoccurs.AA(a) Sample space containing event AFigure 4.4.1Slide 13z “A and B” contains all outcomes which are in both Aand B.(a) Events A and BA BASTAT 110A, UCLA, Ivo DinovProbability distributionsz Probabilities always lie between 0 and 1 and theysum up to 1 (across all simple events) .z pr(A) can be obtained by adding up the probabilitiesof all the outcomes in A.Bpr ( A) (b) “A or B” shaded (c) “A and B” shaded (d) Mutually exclusiveeventsFigure 4.4.2(c) A shadedAn event A in the sample space S.Slide 14z “A or B” contains all outcomes in A or B (or both).A B(b) Event A shadedSTAT 110A, UCLA, Ivo DinovCombining events – all statisticians agree onA BA E outcomein event Apr ( E )Two events.From Chance Encounters by C.J. Wild and G.A.F. Seber, John Wiley & Sons, 2000.Mutually exclusive events cannot occur at the same time.Slide 15Slide 16STAT 110A, UCLA, Ivo DinovReviewSTAT 110A, UCLA, Ivo DinovJob losses in the USz Law of averages for the coin-toss example.z Sample spaces, outcomes, events, complements.z Probabilities are always in the range [0 : 1]TABLE 4.4.1 Job Losses in the US (in thousands)for 1987 to 1991z pr(A) can be obtained by adding up the probabilitiesof all the outcomes in A.pr ( A) E outcomein event ASlide 17pr ( E )STAT 110A, UCLA, Ivo DinovM aleFemaleTotalReason for Job LossWorkplacePositionmoved/closed S lack Slide 18Total3,4472,1375,584STAT 110A, UCLA, Ivo Dinov3

Job losses cont.M aleFemaleTotalWorkplacemoved/closed S lack ished548363911Totalz What is a sample space? What are the two essentialcriteria that must be satisfied by a possible samplespace? (completeness – every outcome is represented; and uniqueness –3,4472,1375,584no outcome is represented more than once.TABLE 4.4.2 Proportions of Job Losses from Table 4.4.1z What is an event? (collection of outcomes)Reason for Job LossWorkplacemoved/closedS lack workPositionabolishedRowtotalsM ale.305.214.098Female.217.101.065.383Column totals.552.315.1631.000Slide 19.617z A sequence of number {p1, p2, p3, , pn } is a probabilitydistribution for a sample space S {s1, s2, s3, , sn}, ifpr(sk) pk, for each 1 k n. The two essentialproperties of a probability distribution p1, p2, , pn?k kz If A and B are events, when does A or B occur?When does A and B occur?Slide 20STAT 110A, UCLA, Ivo DinovProperties of probability distributionsp 0;z If A is an event, what do we mean by itscomplement, A ? When does A occur?p 1Example of probability distributionsz Tossing a coin twice. Sample space S {HH, HT, TH,TT}, for a fair coin each outcome is equally likely, sothe probabilities of the 4 possible outcomes should beidentical, p. Since, p(HH) p(HT) p(TH) p(TT) p andp 0;kkz How do we get the probability of an event from theprobabilities of outcomes that make up that event?STAT 110A, UCLA, Ivo Dinov kp 1kz p ¼ 0.25.z If all outcomes are distinct & equally likely, how do we calculatepr(A) ? If A {a1, a2, a3, , a9} and pr(a1) pr(a2) pr(a9 ) p;thenpr(A) 9 x pr(a1) 9p.Slide 21STAT 110A, UCLA, Ivo DinovProportion vs. Probabilityz How do the concepts of a proportion and aprobability differ? A proportion is a partial description of a realpopulation. The probabilities give us the chance of something happening ina random experiment. Sometimes, proportions are identical to probabilities(e.g., in a real population under the experiment choose-a-unit-at-random).z See the two-way table of counts (contingency table)on Table 4.4.1, slide 19. E.g., choose-a-person-atrandom from the ones laid off, and compute thechance that the person would be a male, laid off dueto position-closing. We can apply the same rules formanipulating probabilities to proportions, in the casewhere these two are identical.Slide 23STAT 110A, UCLA, Ivo DinovSlide 22STAT 110A, UCLA, Ivo DinovRules for manipulatingProbability DistributionsFor mutually exclusive events,pr(A or B) pr(A) pr(B)ABFrom Chance Encounters by C.J. Wild and G.A.F. Seber, John Wiley & Sons, 2000.Slide 24STAT 110A, UCLA, Ivo Dinov4

Unmarried couplesReviewSelect an unmarried couple at random – the table proportions giveus the probabilities of the events defined in the row/column titles.TABLE 4.5.2 Proportions of Unmarried Male-Female CouplesS haring Household in the US , 1991FemaleMaleNever M arriedDivorcedWidowedM arried to otherTotalNeverMarriedDivorcedWidowedMarriedto 591.000Slide 25Totalz If A and B are mutually exclusive, what is theprobability that both occur? (0) What is the probabilitythat at least one occurs? (sum of probabilities)z If we have two or more mutually exclusive events,how do we find the probability that at least one of themoccurs? (sum of probabilities)z Why is it sometimes easier to compute pr(A) frompr(A) 1 - pr( A )? (The complement of the even may be easer to findor may have a known probability. E.g., a random number between 1 and 10 is drawn.Let A {a number less than or equal to 9 appears}. Find pr(A) 1 – pr( A )).probability of A is pr({10 appears}) 1/10 0.1. Also Monty Hall 3 door example!Slide 26STAT 110A, UCLA, Ivo DinovSTAT 110A, UCLA, Ivo DinovConditional ProbabilityMelanoma – type of skin cancer –The conditional probability of A occurring given thatB occurs is given byan example of laws of conditional probabilitiesTABLE 4.6.1: 400 Melanoma Patients by Type and S iteS iteHead andNeckTypeHutchinson'smelanomic freckleSuperficialNodularIndeterminantColumn 61011573282263418512556400pr(A B) Suppose we select one out of the 400 patients in the study and wewant to find the probability that the cancer is on the extremitiesgiven that it is of type nodular: P 73/125 P(C. on Extremities Nodular)# nodular patients with cancer on extremities# nodular patientsContingency table based on Melanoma histological type and its locationSlide 27Slide 28STAT 110A, UCLA, Ivo Dinovpr(A and B) pr(A B)pr(B) pr(B A)pr(A)1.0All people in Israel14% of these are Arabic52% of this 14% are poor7.28% of Israelis are both poor and Arabic(0.52 .014 0.0728)Figure 4.6.1STAT 110A, UCLA, Ivo DinovReviewMultiplication rule- what’s the percentage ofIsraelis that are poor and Arabic?0.072800.14pr(A and B)pr(B)pr( A and B ) pr( A B )pr( B ) pr( B A)pr( A)pr(A) 1 - pr(A)1. Proportions (partial description of a real population) andprobabilities (giving the chance of something happening in a randomexperiment) may be identical – under the experiment choose-aunit-at-random2. Properties of probabilities.{ p } define probabilities p 0;Nkk 1k kp 1kIllustration of the multiplication rule.From Chance Encounters by C.J. Wild and G.A.F. Seber, John Wiley & Sons, 2000.Slide 29STAT 110A, UCLA, Ivo DinovSlide 30STAT 110A, UCLA, Ivo Dinov5

A tree diagram for computingconditional probabilitiesFirstDrawSuppose we draw 2 balls at random one at a timewithout replacement from an urn containing 4 blackand 3 white balls, otherwise identical. What is theprobability that the second ball is black? Sample Spc?SecondDrawA treediagramB21W22B23W24B1MutuallyexclusiveP({2-nd ball is black}) P({2-nd is black} &{1-st is black}) P({2-nd is black} &{1-st is white}) 4/7 x 3/6 4/6 x 3/7 4/7.W1Figure 4.6.2Slide ductEqualspr(Not and Arabic)Poorpr(Poor and Jewish)pr(Not and Jewish)STAT 110A, UCLA, Ivo Dinov2-way table for poverty in Israel cont.PovertyEthnicityJewishArabicpr(Poor and Jewish) pr(Poor Jewish) pr(Jewish)[ 11% of 86%].14.86STAT 110A, UCLA, Ivo Dinov2-way table for poverty in Israelpr(Poor and Arabic) pr(Poor Arabic) pr(Arabic)[ 52% of 14%]PovertyEthnicityJewishArabicPoor.52 .14 .11 .86Not poor?Total.14.86Total?1.00pr(Jewish) .86pr(Arabic) .14Figure 4.6.4pr(Poor and Jewish) pr(Poor Jewish) pr(Jewish)[ 11% of 86%]Proportions by Ethnicity and Poverty.P(A & B) P(A B) x P(B),P(A B) P(A & B) / P(B)P(A & B) P(B & A) P(B A) x P(A).P(A B) [P(B A) x P(A)] / P(B).Slide 34STAT 110A, UCLA, Ivo DinovConditional probabilities and 2-way tablesTotalPoor.52 .14 .11 .86Not poor?TotalSlide 32pr(Poor and Arabic)NotNotSlide 33pr(Poor and Arabic) pr(Poor Arabic) pr(Arabic)[ 52% of 14%]Tree diagram for a sampling problem.STAT 110A, UCLA, Ivo DinovTree diagram for poverty in IsraelPathz Many problems involving conditional probabilitiescan be solved by constructing two-way tables?1.00pr(Jewish) .86pr(Arabic) .14TABLE 4.6.3 Proportions by Ethnicityz This includes reversing the order of conditioningand PovertyEthnicityPovertyPoorNot PoorTotalArabic.0728.0672.14Slide 35Jewish.0946.7654.86Total.1674.83261.00STAT 110A, UCLA, Ivo DinovP(A & B) P(A B) x P(B) P(B A) x P(A)Slide 36STAT 110A, UCLA, Ivo Dinov6

Oral contraceptives cont.Proportional usage of oral contraceptivesand their rates of failurepr(Failed and Oral) pr(Failed Oral) pr(Oral)[ 5% of 32%]We need to complete the two-way contingency table of proportionsSteril.pr(Failed and Oral) pr(Failed Oral) pr(Oral)[ 5% of r(Failed and IUD) pr(Failed IUD) pr(IUD)[ 6% of 3%]IUDSperm.Total.38pr(Steril.) .38.32.24.03.03?Slide 37z How do we interpret the fact that: The event Aalways occurs when B occurs? What can you sayabout pr(A B)?Bz When drawing a probability tree for a particularproblem, how do you know what events to use forthe first fan of branches and which events to use forthe subsequent branching? (at each branching stage condition onall the info available up to here. E.g., at first branching use all simple events, noprior is available. At 3-rd branching condition of the previous 2 events, etc.).DiseasestatusHIVNot HIVTotalFigure 4.6.6Test resultPositive Negative.98 .01?.93?.99?.24?.03.031.00pr(IUD) .03TABLE 4.6.4 Table Constructed from the Data in Example 800Oral.0160.3040Barrier.0336.2064.3200.2400Slide .94081.0000STAT 110A, UCLA, Ivo DinovHaving a Given Mean Absorbance Ratio(MAR) in the ELISA for HIV AntibodiesMARHealthy Donor 22 - 2.99202733456153220297- 3.99- 4.99- 5.99-11.9912 TotalHIV patients} 2750Test cut-off 2} 2 FalseNegatives(FNE)7715362188FalsepositivesPower ofa test is:1-P(FNE) 1-P(Neg HIV) 0.976Adapted from Weiss et al.[1985]Slide 40STAT 110A, UCLA, Ivo DinovHIV – reconstructing the contingency tablepr(HIV and Positive) pr(Positive HIV) pr(HIV)[ 98% of 1%]pr(Not HIV and Negative) pr(Negative Not HIV) pr(Not HIV)[ 93% of 99%].01.99DiseasestatusHIVNot HIVTotalTotalpr(HIV) .01pr(Not HIV) .99Test resultPositive NegativeFrom Chance Encounters by C.J. Wild and G.A.F. Seber, John Wiley & Sons, 2000.Total?.93 .99.01.99?1.00pr(HIV) .01pr(Not HIV) .99TABLE 4.6.6 Proportions by Disease Statusand Test ResultTest ResultDiseaseStatusHIVNot HIVTotalSTAT 110A, UCLA, Ivo Dinovpr(Not HIV and Negative) pr(Negative Not HIV) pr(Not HIV)[ 93% of 99%].98 .01?1.00Putting HIV information into the table.Slide 41TotalSperm.pr(Barrier) .24STAT 110A, UCLA, Ivo DinovHIV cont.pr(HIV and Positive) pr(Positive HIV) pr(HIV)[ 98% of 1%]IUDTABLE 4.6.5 Number of Individualsz In pr(A B), how should the symbol “ ” is readgiven that.Slide 39.32.38STAT 110A, UCLA, Ivo DinovRemarks ATotal1.00pr(IUD) .03pr(Barrier) .24MethodBarrierOral0 .38 .05 .32 .14 .24 .06 .03 .26 .03?pr(Steril.) .38Total0 .38 .05 .32 .14 .24 .06 .03 .26 .03?FailedDidn’tOutcomepr(Failed and IUD) pr(Failed IUD) pr(IUD)[ 6% of 3%]Positive.0098.0693.0791Slide 42Negative.0002.9207.9209Total.01.991.00STAT 110A, UCLA, Ivo Dinov7

Statistical independenceProportions of HIV infections by countryTABLE 4.6.7CountryUnited StatesCanadaAustraliaNew ZealandUnited KingdomIrelandz Events A and B are statistically independent ifknowing whether B has occurred gives no newinformation about the chances of A occurring,Proportions Infected with HIVNo. llions)252.726.716.83.457.33.6Having 039pr(HIV Positive)0.1090.0310.0260.0130.0130.005i.e. ifpr(A B) pr(A)z Similarly, P(B A) P(B), sinceP(B A) P(B & A)/P(A) P(A B)P(B)/P(A) P(B)z If A and B are statistically independent, thenpr( A and B ) pr( A) pr( B )Slide 43Slide 44STAT 110A, UCLA, Ivo DinovPeople vs. CollinsExample using independenceThere are many genetically based blood group systems. Two of these are:Rh blood type system (Rh and Rh-) and the Kell system (K and K-).For Europeans the following proportions are experimentally obtained.92 .81.08 .81.08 .19Table 4.7.1K-TotalRh Rh-?.81.19Total.08.92pr(K ) .08Blood Type Datapr(RH ) .81K Rh Rh-1.00.92TotalK K-.0648.0152.7452.1748.08.92Total.81.191.00.19How can we fill in the inside of the two-way contingency table?It is known that anyone’s blood type in one system is independentof their type in another system.P(Rh and K ) P(Rh ) x P(K ) 0.81 x 0.08 0.0648Slide 45TABLE 4.7.2 Frequencies Assumed by the ProsecutionYellow car110Girl with blond hair13M an with mustache14Black man with beard110Girl with ponytail110Interracial couple in car11000z The first occasion where a conviction was made in an American court of law,largely on statistical evidence, 1964. A woman was mugged and the offenderwas described as a wearing dark cloths, with blond hair in a pony tail whogot into a yellow car driven by a black male accomplice with mustache andbeard. The suspect brought to trial were picked out in a line-up and fit all ofthe descriptions. Using the product rule for probabilities an expert witnesscomputed the chance that a random couple meets these characteristics, as1:12,000,000.Slide 46STAT 110A, UCLA, Ivo DinovSummarySTAT 110A, UCLA, Ivo DinovReviewz What does it mean for two events A and B to bestatistically independent?z Why is the working rule under independence,P(A and B) P(A) P(B) , just a special case of themultiplication rule P(A & B) P(A B) P(B) ?z Mutual independence of events A1, A2, A3, , An if andonly if P(A1 & A2 & & An) P(A1)P(A2) P(An)z What do we mean when we say two humancharacteristics are positively associated? negativelyassociated? (blond hair – blue eyes, pos.; black hair – blue eyes, neg.assoc.)Slide 48STAT 110A, UCLA, Ivo DinovSTAT 110A, UCLA, Ivo Dinovz What happens to the calculated P(A and B) if wetreat positively associated events as independent? ifwe treat negatively associated events as independent?(Example, let B {A {b}}, A & B are pos-assoc’d,P(A&B) P(A)[P(A) P({b})], under indep. assump’s. However,P(A&B) P(B A)P(A) 1 x P(A) P(A)[P(A) P({b})], underestimatingthe real chance of events. If A & B are neg-assoc’d Æ A & comp(B) arepos-assoc’d. In general, this may lead to answers that are grossly too smallor too large )z Why do people often treat events as independent?When can we trust their answers?(Easy computations! Notalways!)Slide 49STAT 110A, UCLA, Ivo Dinov8

Summary of ideasz The probabilities people quote come from 3 main sources: (i) Models (idealizations such as the notion of equallylikely outcomes which suggest probabilities by symmetry). (ii) Data (e.g.relative frequencies with which the event hasoccurred in the past). (iii) subjective feelings representing a degree of beliefz A simple probability model consists of a samplespace and a probability distribution.Summary of ideas cont.z A list of numbers p1, p2, is a probabilitydistribution for S {s1, s2, s3, }, provided all of the pi's lie between 0 and 1, and they add to 1.z According to the probability model, pi is theprobability that outcome si occurs.z We write pi P(si).z A sample space, S, for a random experiment is the setof all possible outcomes of the experiment.Slide 50Summary of ideas cont.z An event is a collection of outcomesz An event occurs if any outcome making up that eventoccursz The probability of event A can be obtained by addingup the probabilities of all the outcomes in Az If all outcomes are equally likely,number of outcomes in Apr(A) total number of outcomesSlide 52Slide 51STAT 110A, UCLA, Ivo DinovSummary of ideas cont.z It is useful to represent events diagrammatically using Venndiagramsz A union of events, A or B contains all outcomes in A or B(including those in both). It occurs if at least one of A or Boccursz An intersection of events, A and B contains all outcomeswhich are in both A and B. It occurs only if both A and Boccurz Mutually exclusive events cannot occur at the same timeSlide 53Summary of ideas cont.pr(A B) pr(B)z Events A and B are statistically independent if knowing whetherB has occurred gives no new information about the chances of Aoccurring, i.e. if P(A B) P(A) Æ P(B A) P(B).z If events are physically independent, then, under any sensibleprobability model, they are also statistically independentAz The complement of an event A, denoted A , occurs if A doesnot occurSTAT 110A, UCLA, Ivo Dinovz The conditional probability of A occurring given that B occurs isgiven bypr(A and B)STAT 110A, UCLA, Ivo DinovSTAT 110A, UCLA, Ivo DinovFormula Summaryz For discrete sample spaces, pr(A) can be obtained byadding the probabilities of all outcomes in Az For equally likely outcomes in a finite sample spacepr(A) number of outcomes in Atotal number of outcomesz Assuming that events are independent when in reality they arenot can often lead to answers that are grossly too big or grosslytoo smallSlide 54STAT 110A, UCLA, Ivo DinovSlide 55STAT 110A, UCLA, Ivo Dinov9

Formula summary cont.Formula summary cont.Conditional probabilityz pr(S) 1z Definition:z pr( A ) 1 - pr(A)pr(A B) z If A and B are mutually exclusive events, thenpr(A or B) pr(A) pr(B)(here “or” is used in the inclusive sense)pr(A and B)pr(B)z Multiplication formula:z If A1, A2, .,Ak are mutually exclusive events, thenpr(A and B) pr(B A)pr(A) pr(A B)pr(B)pr(A1 or A2 or or Ak ) pr(A1) pr(A2) pr(Ak)Slide 56Formula summary cont.Multiplication Rule under independence:z If A and B are independent events, thenpr(A and B) pr(A) pr(B)z If A1, A2, , An are mutually independent,pr(A1 and A2 and . and An) pr(A1) pr(A2) pr(An)Slide 58Slide 57STAT 110A, UCLA, Ivo DinovTheory of Counting Combinatorial AnalysisPrinciple of Counting: If 2 experiments are performed andthe first one has N1 possible outcomes, the second(independent) experiment has N2 possible outcomes thenthe number of outcomes of the combined (dual)experiment is N1 x N2.E.g., Suppose we have 5 math majors in the class,each carrying 2 textbooks with them. If I select amath major student and 1 textbook at random, howmany possibilities are there? 5x2 10Slide 59STAT 110A, UCLA, Ivo DinovPermutation: Number of ordered arrangements of robjects chosen from n distinctive objectsPnr n ( n 1)( n 2 ) ( n r 1)P nn P nn r · P r rN1xN2x x NM.E.g., How many binary functions [f(i) 0 or f(i) 1],defined on a grid 1, 2, 3, , n, are there? Howmany numbers can be stored in 8 bits 1 byte?STAT 110A, UCLA, Ivo DinovPermutation & CombinationTheory of Counting Combinatorial AnalysisGeneralized Principle of Counting: If M (independent)experiments are performed and the first one has Nmpossible outcomes, 1 m M, then the TOTAL numberof outcomes of the combined experiment isSTAT 110A, UCLA, Ivo Dinove.g.P63 6·5·4 120.2 x 2 x x 2 2nSlide 60STAT 110A, UCLA, Ivo DinovSlide 61STAT 110A, UCLA, Ivo Dinov10

Permutation & CombinationPermutation & CombinationCombination: Number of non-orderedarrangements of r objects chosen from ndistinctive objects:rrCn Pn / r! Or use notation ofe.g. 3! 6 , 5! 120 , 0! 1( ) CnrrnCombinatorial Identity:n!(n r )!r!( ) 47!3!! 3573nn rAnalytic proof: (expand both hand sides)Combinatorial argument: Given n objects the number ofcombinations of choosing any r of them is equivalent tochoosing the remaining n-r of them (order-of-objs-notimportant!)Slide 64b) P262 · P103 26·25·10·9·8·7STAT 110A, UCLA, Ivo DinovExamples2. How many different letter arrangement canbe made from the 11 letters of MISSISSIPPI?Solution: There are: 1 M, 4 I, 4 S, 2 P letters.Method 1: consider different permutations:11!/(1!4!4!2!) 34650Method 2: consider combinations:( ) ( ) ( ) ( ) . ( ) ( ) ( ) ( )112Slide 66STAT 110A, UCLA, Ivo DinovSolution: a) 26·26·10·10·10·10Slide 65STAT 110A, UCLA, Ivo DinovExamples22Analytic proof: (expand both hand sides)Combinatorial argument: Given n object focus on one ofthem (obj. 1). There are § nr 11· ¹ groups of size r that containobj. 1 (since each group contains r-1 other elements outof n-1). Also, there are § n r 1· ¹groups of size r, that do1. Suppose car plates are 7-digit, like AB1234. If all theletters can be used in the first 2 places, and all numberscan be used in the last 4, how many different plates canbe made? How many plates are there with no repeatingdigits?( ) ( )64n 1rExamplesCombinatorial Identity:104n 1r 1Slide 63STAT 110A, UCLA, Ivo DinovPermutation & Combination111nrnot contain obj1.But the total of all r-size groupsof n-objects is § nr · ¹ !Slide 62nr( ) ( ) ( )9454STAT 110A, UCLA, Ivo Dinov113. There are N telephones, and any 2 phonesare connected by 1 line. Then how manylines are needed all together?Solution: C2N N (N - 1) / 2If, N 5, complete graph with 5 nodes hasC25 10 edges.Slide 67STAT 110A, UCLA, Ivo Dinov11

ExamplesExamples4. N distinct balls with M of them white. Randomlychoose n of the N balls. What is the probability that thesample contains exactly m white balls (suppose every ballis equally likely to be selected)?b) Then the probability is( )(Later These ProbabilitiesWill be associated with the nameHyperGeometric(N, n, M) distrib.( )(MmSlide 68N Mn mN Mn mThere are M! ways of ordering the girls amongthemselves. NOTE – if girls are indistinguishablethen there’s no need for this factor!Solution: N!· N 1 ·M!)MThere are N 1 slots for the girls to fill between the boysAnd there are M girls to position in these slots, hencethe coefficient in the middle.)/ ( )STAT 110A, UCLA, Ivo DinovThere are N! ways of orderingthe boys among themselves( )Solution: a) For the event to occur, m out of M whiteballs are chosen, and n-m out of N-M non-whiteballs are chosen. And we getMm5. N boys ( ) and M girls ( ), M N 1, stand in 1line. How many arrangements are there so that no2 girls stand next to each other?NnHow about theyare arranged in a circle?Answer: N! ( NM) M!E.g., N 3, M 2Slide 69STAT 110A, UCLA, Ivo DinovExamplesExamples5a. How would this change if there are N functional( ) and M defective chips ( ), M N 1, in anassembly line?5a. How would this change if there are N functional( ) and M defective chips ( ), M N 1, in anassembly line?( )N 1MSolution:Solution:There are N 1 slots for the girls to fill between the boysAnd there are M girls to position in these slots, hencethe coefficient in the middle.Slide 70( )N 1MThere are N 1 slots for the girls to fill between the boysAnd there are M girls to position in these slots, hencethe coefficient in the middle.Slide 71STAT 110A, UCLA, Ivo DinovBinomial theorem & multinomial theoremMultinomial theoremnnBinomial theorem ( a b ) ( )ankknbn k(a b )n k 0Deriving from this, we can get such useful formula (a b 1)( ) ( ) . ( ) 2 (1 1)n0n1nnnnAlso from (1 x)m n (1 x) m(1 x)n we obtain:( ) ( )( )m nkki 0miOn the left is the coeff of 1kx(m n-k). On the right is the same coeff in the productof ( coeff * x(m-i) ) * ( coeff * x(n-k i) ).Slide 72STAT 110A, UCLA, Ivo Dinov ( )ankkbn kk 0Generalization: Divide n distinctive objects into k groups,with the size of every grou

1 STAT 110A, UCLA, Ivo Dinov Slide 1 UCLA STAT 110 A Applied Probability & Statistics for Engineers Instructor: Ivo Dinov, Asst. Prof. In Statistics and Neurology StatisticsTeaching Assistant: Maria Chang