SlideShare a Scribd company logo
9/22/2018
1
SBE 304: Bio-Statistics
Probability
Dr. Ayman Eldeib
Systems & Biomedical
Engineering Department
Fall 2018
SBE 304: Probability
Outline
• Introduction
• Review of Venn Diagrams & Set Notation
• A Probabilistic Model for an Experiment
• The Probability of an Event
• Theory of Probability
• Calculating the Probability of an Event
• Tools for counting sample points/events
• Characterizing a set of Measurements
9/22/2018
2
SBE 304: Probability
Statistics
Descriptive Inferential
Correlational GeneralisingOrganising,
summarising &
describing data
Significance
Introduction
Relationships
SBE 304: Probability
General Definition
 The mathematical theory of probability deals
with patterns that occur in random events.
 Probability is a way of expressing knowledge
or belief that an event will occur. The
probability of a random event denotes the
relative frequency of occurrence of an
experiment's outcome, when repeating the
experiment.
 Probability is a way to represent an
individual’s degree of belief in a statement, or
an objective degree of rational belief, given
the evidence.
9/22/2018
3
SBE 304: Probability
Venn Diagrams & Set Notation
Universal Set
Let's say that our universe contains the numbers 1, 2, 3,
and 4; i.e. S = {1, 2, 3, 4}.
Subset
Let A be the set containing the numbers 1 and 2; that is, A =
{1, 2}.
A ⊆ S
Let B be the set containing the numbers 2 and 3; that is, B =
{2, 3}.
B ⊆ S
The Venn diagram is made up of two or more non- or
overlapping circles/shapes. It is often used in mathematics to
show relationships between sets.
SBE 304: Probability
Venn Diagrams & Set Notation Cont.
Set notation pronunciation meaning Venn diagram answer
A U B "A union B"
Everything that is in
either of the sets {1, 2, 3}
A ^ B
or
( A ∩ B)
"A intersect B"
only the things that are in
both of the sets {2}
Ac
or ~A or A
"A complement",
or "not A"
Everything in the universe
outside of A {3, 4}
A – B
"A minus B", or
"A complement B"
everything in A except for
anything in its overlap
with B
{1}
~(A U B) "not (A union B)"
Everything outside
A and B {4}
~(A ^ B)
or
~( A ∩ B)
"not (A intersect B)"
everything outside of the
overlap of A and B {1, 3, 4}
-
9/22/2018
4
SBE 304: Probability
Venn Diagrams & Set Notation
Null Set
The Null, or empty, set denoted by Ø, is the set consisting
of no points/members. Thus, Ø is a subset of every set.
Mutually Exclusive or Disjoint
Two sets, A and B are said to be disjoint if A ∩ B = Ø.
Cont.
SBE 304: Probability
Venn Diagrams & Set Notation
Given the following Venn diagram, shade in
A ∩ C
Examples
Given the following Venn diagram, shade in
A U (B – C)
(B – C) U A
Cont.
A ∩ C
9/22/2018
5
SBE 304: Probability
Venn Diagrams & Set Notation
 (A‘) ‘= A
 The distributive law for set operations implies that
 (A ∪ B) ∩ C = (A ∩ C) ∪ (B ∩ C)
 (A ∩ B) ∪ C = (A ∪ C) ∩ (B ∪ C)
 DeMorgan’s laws imply that
 (A ∪ B) ‘ = A‘ ∩ B‘
 (A ∩ B) ‘ = A‘ ∪ B‘
 Also, remember that
 A ∪ B = B ∪ A
 A ∩ B = B ∩ A
Cont.
SBE 304: Probability
A Probabilistic Model for an Experiment
A spinner has 4 equal sectors colored yellow, blue, green and
red. What are the chances of landing on blue after spinning
the spinner? What are the chances of landing on red?
Problem
Solution
The chances of landing on blue are 1 in 4, or one fourth.
The chances of landing on red are 1 in 4, or one fourth.
9/22/2018
6
SBE 304: Probability
A Probabilistic Model for an Experiment
Definition Example
An experiment is a situation involving
chance or probability that leads to
results called outcomes. It is the process
by which an observation is made
In the problem above, the experiment
is spinning the spinner.
An outcome is the result of a single trial
of an experiment.
The possible outcomes are landing on
yellow, blue, green or red.
An event is one or more outcomes of an
experiment.
One event of this experiment is landing
on blue.
Probability is the measure of how likely
an event is.
The probability of landing on blue is
one fourth.
Cont.
SBE 304: Probability
The Probability of an Event
Probability Of An Event
P(A) =
The Number Of Ways Event A Can Occur
The total number Of Possible Outcomes
The probability of event A is the number of ways
event A can occur divided by the total number of
possible outcomes.
9/22/2018
7
SBE 304: Probability
The Probability of an Event
A spinner has 4 equal sectors colored yellow, blue, green
and red. After spinning the spinner, what is the probability
of landing on each color?
Experiment
Outcomes
The possible outcomes of this experiment are yellow, blue,
green, and red
Cont.
SBE 304: Probability
Probabilities
P(yellow) =
# of ways to land on yellow
total # of colors
=
1
4
P(blue) =
# of ways to land on blue
total # of colors
=
1
4
P(green) =
# of ways to land on green
total # of colors
=
1
4
P(red) =
# of ways to land on red
total # of colors
=
1
4
Cont.
The Probability of an Event
9/22/2018
8
SBE 304: Probability
A single 6-sided die is rolled. What is the probability of
each outcome? What is the probability of rolling an even
number? of rolling an odd number?
Experiment
Outcomes
The possible outcomes of this experiment are 1, 2, 3, 4, 5
and 6.
Cont.
The Probability of an Event
SBE 304: Probability
P(3) =
# of ways to roll a 3
total # of sides
=
1
6
P(even) = # ways to roll an even number
total # of sides
=
3
6
=
1
2
P(odd) = # ways to roll an odd number
total # of sides
=
3
6
=
1
2
Probabilities
Cont.
The Probability of an Event
9/22/2018
9
SBE 304: Probability
Theory of Probability
A set of all possible outcomes. It is usually denoted by S
The Sample Space
A Discrete Sample Space
It contains either a finite or a countable number of distinct
sample points/events.
SBE 304: Probability
Event Probability
A
not A
A and B
A or B
A given B
The Multiplicative Law
The Additive Law
Bayes’ Rule
Cont.
Theory of Probability
9/22/2018
10
SBE 304: Probability
P(A ∩ B) =
The Number Of Ways Event A ∩ B Can Occur
The total number Of Possible Outcomes
P(A|B) = P(A∩ B)/P(B)
The Number Of Ways Event A ∩ B Can Occur
The Number Of Ways Event B Can Occur
P(B) =
The Number Of Ways Event B Can Occur
The total number Of Possible Outcomes
Note: P(A|B)P(B) = P(A∩ B) = P(B|A)P(A)
Cont.
Theory of Probability
SBE 304: Probability
 P(A|B) = P(A∩B) / P(B)
 P(B|A) = P(B∩A) / P(A)
 P(A∩B) = P(A|B) P(B)
 P(B|A) P(A) = P(A∩B) = P(A|B) P(B)
 P(B|A) = P(A|B) P(B) / P(A)
 P(B|A) = P(A|B)P(B) / (P(A|B)P(B) + P(A|B‘)P(B‘))
?
Cont.
Theory of Probability
9/22/2018
11
SBE 304: Probability
 B∪B‘ = Ω, the universal event.
 B∩B‘ = Φ, an empty event.
 A = A ∩ (B ∪ B‘)
 A = A∩B ∪ A∩B‘
since A∩B and A∩B ‘ are mutually exclusive
 P(A) = P(A∩B ∪ A∩B ‘)
 P(A) = P(A∩B) + P(A∩B ‘)
 P(A) = P(A|B)P(B) + P(A|B ‘)P(B ‘)
Cont.
Theory of Probability
SBE 304: Probability
 A doctor is called to see a sick child. The doctor has prior
information that 90% of sick children in that neighborhood
have the flu, while the other 10% are sick with measles. Let
F stand for an event of a child being sick with flu and M
stand for an event of a child being sick with measles.
Assume for simplicity that F ∪ M = Ω, i.e., that there no other
maladies in that neighborhood.
 A well-known symptom of measles is a rash (the event of
having which we denote R). P(R|M) = .95. However,
occasionally children with flu also develop rash, so that
P(R|F) = 0.08.
 Upon examining the child, the doctor finds a rash. What is
the probability that the child has measles?.
Example I
Cont.
Theory of Probability
9/22/2018
12
SBE 304: Probability
 P(M|R) = .95 × .10 / (.95 × .10 + .08 × .90)
 P(M|R) ≈ 0.57
Solution I
Cont.
Theory of Probability
P(R|M) P(M) / (P(R|M) P(M) + P(R|F) P(F)) P(M|R) =
SBE 304: Probability
 In a study, physicians were asked what the odds of breast
cancer would be in a woman who was initially thought to
have a 1% risk of cancer but who ended up with a positive
mammogram result (a mammogram accurately classifies
about 80% of cancerous tumors and 90% of benign tumors.)
 95 out of a hundred physicians estimated the probability of
cancer to be about 75%. Do you agree?
Example II
Introduce the events:
P - mammogram result is positive,
B - tumor is benign,
M - tumor is malignant.
Cont.
Theory of Probability
9/22/2018
13
SBE 304: Probability
Introduce the events:
P - mammogram result is positive,
B - tumor is benign,
M - tumor is malignant.
Bayes' formula in this case is
P(M|P) = P(P|M) P(M) / (P(P|M) P(M) + P(P|B) P(B))
= .80 × .01 / (.80 × .01 + .10 × .99)
≈ 0.075
≈ 7.5%.
A far cry from a common estimate of 75%.
Solution II
Cont.
Theory of Probability
SBE 304: Probability
Calculating the Probability of an Event
I. Define the experiment.
II. List all the simple outcomes associated with the
experiment. These outcomes constitute the sample
space.
III. Assign reasonable probabilities to these outcomes.
Make sure each probability is greater than or equal to
zero and the sum of the probabilities is 1. If all
outcomes are equally likely the probability of each will
be 1/n.
IV. Define the event of interest A and see the outcomes in
the sample space which makes A occur.
V. Find P(A) by adding the probabilities of these outcomes
which make A occur.
9/22/2018
14
SBE 304: Probability
 If the sample space contains a very large number of
sample points, complete itemization will be tedious, time
consuming and might be practically impossible.
 When this occurs we need not list the points but just use
combinatorial analysis to know the number of points in the
sample space (N) and the event space (n).
 If outcomes are equally likely the probability of the event is
n/N.
Notes:
Cont.
Calculating the Probability of an Event
SBE 304: Probability
P(A ∪ B ∪ C) = P((A ∪ B) ∪ C)
= P(A ∪ B) + P(C) – P((A ∪ B) ∩ C)
= P(A) + P(B) – P(A ∩ B) + P(C)
– P((A ∩ C) ∪ (B ∩ C))
= P(A) + P(B) + P(C) – P(A ∩ B)
-[P(A ∩ C) + P(B ∩ C) – P(A ∩B ∩ C)]
= P(A) + P(B) + P(C) – P(A ∩ B)
- P(A ∩ C) - P(B ∩ C) + P(A ∩B ∩ C)
Three or More Events
Cont.
Calculating the Probability of an Event
 P(A ∪ B) = P(A) + P(B) – P(A ∩ B)
9/22/2018
15
SBE 304: Probability
 A collection of events, E1, E2, …Ek, is said to be mutually
exclusive for all pairs:
Ei ∩ Ej = Φ, an empty event
Three or More Events
For a collection of mutually exclusive events,
P(E1 ∪ E2 ∪ ….. ∪ Ek) = P(E1) + P(E2) + …… + P(Ek)
Cont.
Calculating the Probability of an Event
SBE 304: Probability
 P(A) = P(A∩B) + P(A∩B ‘)
 P(A) = P(A|B)P(B) + P(A|B ‘)P(B ‘)
 In general, a collection of mutually exclusive sets, E1, E2,
…Ek, such that E1 ∪ E2 ∪ ….. ∪ Ek = S, is said to be
exhaustive.
 P(A) = P(A∩E1) + P(A∩E2) + ….. P(A ∩ Ek)
 P(A) = P(A| E1)P(E1) + P(A| E2)P(E2) + ….. + P(A| Ek)P(Ek)
 P(Ej| A) = P(A| Ej)P(Ej) / ∑ P(A| Ei)P(Ei) {i=1,2, ….,k)}
Three or More Events Total Probability Rule
Cont.
Calculating the Probability of an Event
9/22/2018
16
SBE 304: Probability
Tools for counting sample points/events
Multiplication of Choices
With m elements a1, a2, ….., am and n elements b1, b2,
….., bn, it is possible to form mn = m * n pairs containing
one element from each group
SBE 304: Probability
Multiplication of Choices
Example:
There are seven different trails to the top of the mountain. In how
many different ways can a person hike up and down the
mountain if
1.he must take the same trail both ways;
2.he can, but need not, take the same trail both ways;
3.he does not want to take the same trail both ways.
7 * 7
7 * 6
7
Cont.
Tools for counting sample points/events
9/22/2018
17
SBE 304: Probability
Permutation
An ordered arrangement of r distinct objects is called a
permutation (n!). The number of ways of ordering n distinct
objects taken r at a time will be designed by the symbol
Pr
n
Pr
n = n(n - 1)(n - 2)…..(n – r + 1) = n! / (n - r)!
Tools for counting sample points/events Cont.
SBE 304: Probability
Permutation
Consider a set of elements, such as S {a, b, c}. A
permutation of the elements is an ordered sequence of
the elements. For example, abc, acb, bac, bca, cab, and cba
are all of the permutations of the elements of S.
Example:
n! = n(n - 1)(n - 2)…..(1)
3! = 3 * 2 * 1 = 6
Cont.
Tools for counting sample points/events
9/22/2018
18
SBE 304: Probability
Permutation
A printed circuit board has eight different locations in which a
component can be placed. If four different components are to be
placed on the board, how many different designs are possible?
Example:
Each design consists of selecting a location from the eight locations
for the first component, a location from the remaining seven for the
second component, a location from the remaining six for the third
component, and a location from the remaining five for the fourth
component. Therefore,
P4
8 = 8*7*6*5= 8! / (8 - 4)! = 1680
1680 different designs are possible.
Cont.
Tools for counting sample points/events
SBE 304: Probability
Partitioning n distinct objects into k distinct groups
The number of ways N of partitioning n distinct objects into
k distinct groups containing n1, n2, ….., nk, objects,
respectively, where each object appears in exactly one
group and ∑ ni = n, where i=1, 2, ….., k, is
N = ( )n
n1 n2 ….. nk =
________________
n!
n1! n2! ….. nk!
Tools for counting sample points/events Cont.
9/22/2018
19
SBE 304: Probability
Partitioning n distinct objects into k distinct groups
A part is labeled by printing with four thick lines, three
medium lines, and two thin lines. If each ordering of the
nine lines represents a different label, how many different
labels can be generated by using this scheme?
Example:
( )N =
n
n1 n2 ….. nk =
________________
n!
n1! n2! ….. nk!
= 9!/4!3!2!
Cont.
Tools for counting sample points/events
SBE 304: Probability
Combinations
The number of unordered subsets of size r chosen
(without replacement) from n available objects is
( )n
r =
C
n
r = ________________
n!
r! (n – r)!
Cont.
Tools for counting sample points/events
9/22/2018
20
SBE 304: Probability
Combinations
Consider the problem of choosing two patient monitoring systems for
ICU out of a group of five and imagine that the monitoring systems
vary in competence, 1 being the best, 2 second best, and so on, for 3,
4, and 5. These rating are of course unknown to the nurse.
A- Find the number of ways of selecting two systems out of five.
B- Let A denote the event that exactly one of the two best systems
appears in a selection of two out of five. Find the number of sample
points in A and P(A).
Example:
(5
2) = 5!/2!3! = 10
n = (2
1) (3
1) = 2*3=6 P(A) = 0.6
Cont.
Tools for counting sample points/events
SBE 304: Probability
When male and female workers become sick, what do they do? A
survey was carried out and the responses of 500 workers were
tabulated
Example:
Action Male (M) Female
Consult a doctor (D) 115 70
Consult a pharmacist for a pain killer medication 60 140
Go to a hospital 75 40
1. What is the probability that a man would consult a pharmacist?
2. What proportion of workers consults a doctor?
3. If a worker is known to be a female, what is the probability that she will go to a
hospital?
4. Among workers consulting a pharmacist, what proportion are males?
5. Are gender and consulting a doctor independent? Verify your answer.
Dependent: P(D) ≠ P(D|M)
60/200 = 0.3
60/500 = 0.12
185/500 = 0.37
40/250 = 0.16
9/22/2018
21
SBE 304: Probability
Characterizing a set of Measurements
The Mean
The mean of a sample of n measured responses
y1, y2, ….., yn is given by
Y =
__
___1
n
∑
n
i = 1
yiµ =
SBE 304: Probability
Characterizing a set of Measurements
The Variance
The variance of a sample of measurements y1, y2, ….., yn
is the sum of the differences between the measurements
and their mean, divided by n – 1.
S2 =
_______1
n - 1
∑
n
i = 1
(yi – µ)2
σ 2 =
9/22/2018
22
SBE 304: Probability
Characterizing a set of Measurements
The standard deviation
The standard deviation of a sample of measurements is
the positive square root of the variance; that is,
S = S2 = σ 2 = σ
SBE 304: Probability
Characterizing a set of Measurements
Graphical Methods – Frequency Histogram
A frequency distribution is a
tabulation of the values that one
or more variables take in a
sample. Each entry in the table
contains the frequency or count
of the occurrences of values
within a particular group or
interval, and in this way the
table summarizes the
distribution of values in the
sample.
Rank Degree of agreement Number
1 Strongly agree 20
2 Agree somewhat 30
3 Not sure 20
4 Disagree somewhat 15
5 Strongly disagree 15
9/22/2018
23
SBE 304: Probability
Characterizing a set of Measurements
Graphical Methods – Frequency Histogram
0
5
10
15
20
25
30
35
Strongly agree Agree
somewhat
Not sure Disagree
somewhat
Strongly
disagree
1 2 3 4 5
Number
Number
g{tÇ~ lÉâg{tÇ~ lÉâg{tÇ~ lÉâg{tÇ~ lÉâ

More Related Content

PPTX
Bayes Theorem
PPTX
Probabilistic Reasoning
PPTX
Probability
PDF
Chap 2 (1).pdf
PDF
02 Machine Learning - Introduction probability
PPTX
Basic Concepts of Probability
PPT
03+probability+distributions.ppt
Bayes Theorem
Probabilistic Reasoning
Probability
Chap 2 (1).pdf
02 Machine Learning - Introduction probability
Basic Concepts of Probability
03+probability+distributions.ppt

Similar to Lec 1 probability (20)

PPT
Chapter 4 Probability Notes
PPT
PPTX
CHAPTER ONE_ Basic Probability Theory (1).pptx
PPT
Chapter06
PPT
probability
PPT
AlfordChapter4.ppt
PPTX
Probability__________________________.pptx
PPTX
LU2 Basic Probability
PPT
Sfs4e ppt 05
PPT
Stats Chapter 5 Lesson 1 power point
PPTX
Probability
PPTX
probibility
PPTX
THIRD COT-PROBABILITY-OF-SIMPLE-EVENTS.pptx
PPTX
COT-PROBABILITY-OF-SIMPLE-EVENTS.pptx THIRD QUARTER
PPTX
COT-PROBABILITY-OF-SIMPLE-EVENTS.pptx 3RD QUARTER
PPTX
Basic concepts of probability
PPTX
L1-Fundamentals of Probability. gives fundamentals of statistics and probabil...
PPTX
SAMPLE SPACES and PROBABILITY (3).pptx
KEY
Introduction to Probability
KEY
What are the chance? - Probability
Chapter 4 Probability Notes
CHAPTER ONE_ Basic Probability Theory (1).pptx
Chapter06
probability
AlfordChapter4.ppt
Probability__________________________.pptx
LU2 Basic Probability
Sfs4e ppt 05
Stats Chapter 5 Lesson 1 power point
Probability
probibility
THIRD COT-PROBABILITY-OF-SIMPLE-EVENTS.pptx
COT-PROBABILITY-OF-SIMPLE-EVENTS.pptx THIRD QUARTER
COT-PROBABILITY-OF-SIMPLE-EVENTS.pptx 3RD QUARTER
Basic concepts of probability
L1-Fundamentals of Probability. gives fundamentals of statistics and probabil...
SAMPLE SPACES and PROBABILITY (3).pptx
Introduction to Probability
What are the chance? - Probability
Ad

More from cairo university (20)

PPSX
Tocci chapter 13 applications of programmable logic devices extended
PPSX
Tocci chapter 12 memory devices
PPSX
Tocci ch 9 msi logic circuits
PPSX
Tocci ch 7 counters and registers modified x
PPSX
Tocci ch 6 digital arithmetic operations and circuits
PPSX
Tocci ch 3 5 boolean algebra, logic gates, combinational circuits, f fs, - re...
PPSX
A15 sedra ch 15 memory circuits
PPSX
A14 sedra ch 14 advanced mos and bipolar logic circuits
PPSX
A13 sedra ch 13 cmos digital logic circuits
PPSX
A09 sedra ch 9 frequency response
PPTX
5 sedra ch 05 mosfet.ppsx
PPSX
5 sedra ch 05 mosfet
PPSX
5 sedra ch 05 mosfet revision
PDF
Fields Lec 2
PDF
Fields Lec 1
PDF
Fields Lec 5&6
PDF
Fields Lec 4
PDF
Fields Lec 3
PPT
Lecture 2 (system overview of c8051 f020) rv01
PPT
Lecture 1 (course overview and 8051 architecture) rv01
Tocci chapter 13 applications of programmable logic devices extended
Tocci chapter 12 memory devices
Tocci ch 9 msi logic circuits
Tocci ch 7 counters and registers modified x
Tocci ch 6 digital arithmetic operations and circuits
Tocci ch 3 5 boolean algebra, logic gates, combinational circuits, f fs, - re...
A15 sedra ch 15 memory circuits
A14 sedra ch 14 advanced mos and bipolar logic circuits
A13 sedra ch 13 cmos digital logic circuits
A09 sedra ch 9 frequency response
5 sedra ch 05 mosfet.ppsx
5 sedra ch 05 mosfet
5 sedra ch 05 mosfet revision
Fields Lec 2
Fields Lec 1
Fields Lec 5&6
Fields Lec 4
Fields Lec 3
Lecture 2 (system overview of c8051 f020) rv01
Lecture 1 (course overview and 8051 architecture) rv01
Ad

Recently uploaded (20)

PPTX
additive manufacturing of ss316l using mig welding
PDF
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
PDF
PPT on Performance Review to get promotions
PPTX
web development for engineering and engineering
PDF
SM_6th-Sem__Cse_Internet-of-Things.pdf IOT
PPTX
Fundamentals of safety and accident prevention -final (1).pptx
PDF
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
PPTX
Current and future trends in Computer Vision.pptx
DOCX
573137875-Attendance-Management-System-original
PDF
Model Code of Practice - Construction Work - 21102022 .pdf
PDF
BIO-INSPIRED HORMONAL MODULATION AND ADAPTIVE ORCHESTRATION IN S-AI-GPT
PPTX
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
PDF
737-MAX_SRG.pdf student reference guides
PPTX
UNIT 4 Total Quality Management .pptx
PPTX
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
PPTX
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PDF
PREDICTION OF DIABETES FROM ELECTRONIC HEALTH RECORDS
PPTX
Internet of Things (IOT) - A guide to understanding
PDF
Unit I ESSENTIAL OF DIGITAL MARKETING.pdf
additive manufacturing of ss316l using mig welding
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
PPT on Performance Review to get promotions
web development for engineering and engineering
SM_6th-Sem__Cse_Internet-of-Things.pdf IOT
Fundamentals of safety and accident prevention -final (1).pptx
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
Current and future trends in Computer Vision.pptx
573137875-Attendance-Management-System-original
Model Code of Practice - Construction Work - 21102022 .pdf
BIO-INSPIRED HORMONAL MODULATION AND ADAPTIVE ORCHESTRATION IN S-AI-GPT
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
737-MAX_SRG.pdf student reference guides
UNIT 4 Total Quality Management .pptx
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PREDICTION OF DIABETES FROM ELECTRONIC HEALTH RECORDS
Internet of Things (IOT) - A guide to understanding
Unit I ESSENTIAL OF DIGITAL MARKETING.pdf

Lec 1 probability

  • 1. 9/22/2018 1 SBE 304: Bio-Statistics Probability Dr. Ayman Eldeib Systems & Biomedical Engineering Department Fall 2018 SBE 304: Probability Outline • Introduction • Review of Venn Diagrams & Set Notation • A Probabilistic Model for an Experiment • The Probability of an Event • Theory of Probability • Calculating the Probability of an Event • Tools for counting sample points/events • Characterizing a set of Measurements
  • 2. 9/22/2018 2 SBE 304: Probability Statistics Descriptive Inferential Correlational GeneralisingOrganising, summarising & describing data Significance Introduction Relationships SBE 304: Probability General Definition  The mathematical theory of probability deals with patterns that occur in random events.  Probability is a way of expressing knowledge or belief that an event will occur. The probability of a random event denotes the relative frequency of occurrence of an experiment's outcome, when repeating the experiment.  Probability is a way to represent an individual’s degree of belief in a statement, or an objective degree of rational belief, given the evidence.
  • 3. 9/22/2018 3 SBE 304: Probability Venn Diagrams & Set Notation Universal Set Let's say that our universe contains the numbers 1, 2, 3, and 4; i.e. S = {1, 2, 3, 4}. Subset Let A be the set containing the numbers 1 and 2; that is, A = {1, 2}. A ⊆ S Let B be the set containing the numbers 2 and 3; that is, B = {2, 3}. B ⊆ S The Venn diagram is made up of two or more non- or overlapping circles/shapes. It is often used in mathematics to show relationships between sets. SBE 304: Probability Venn Diagrams & Set Notation Cont. Set notation pronunciation meaning Venn diagram answer A U B "A union B" Everything that is in either of the sets {1, 2, 3} A ^ B or ( A ∩ B) "A intersect B" only the things that are in both of the sets {2} Ac or ~A or A "A complement", or "not A" Everything in the universe outside of A {3, 4} A – B "A minus B", or "A complement B" everything in A except for anything in its overlap with B {1} ~(A U B) "not (A union B)" Everything outside A and B {4} ~(A ^ B) or ~( A ∩ B) "not (A intersect B)" everything outside of the overlap of A and B {1, 3, 4} -
  • 4. 9/22/2018 4 SBE 304: Probability Venn Diagrams & Set Notation Null Set The Null, or empty, set denoted by Ø, is the set consisting of no points/members. Thus, Ø is a subset of every set. Mutually Exclusive or Disjoint Two sets, A and B are said to be disjoint if A ∩ B = Ø. Cont. SBE 304: Probability Venn Diagrams & Set Notation Given the following Venn diagram, shade in A ∩ C Examples Given the following Venn diagram, shade in A U (B – C) (B – C) U A Cont. A ∩ C
  • 5. 9/22/2018 5 SBE 304: Probability Venn Diagrams & Set Notation  (A‘) ‘= A  The distributive law for set operations implies that  (A ∪ B) ∩ C = (A ∩ C) ∪ (B ∩ C)  (A ∩ B) ∪ C = (A ∪ C) ∩ (B ∪ C)  DeMorgan’s laws imply that  (A ∪ B) ‘ = A‘ ∩ B‘  (A ∩ B) ‘ = A‘ ∪ B‘  Also, remember that  A ∪ B = B ∪ A  A ∩ B = B ∩ A Cont. SBE 304: Probability A Probabilistic Model for an Experiment A spinner has 4 equal sectors colored yellow, blue, green and red. What are the chances of landing on blue after spinning the spinner? What are the chances of landing on red? Problem Solution The chances of landing on blue are 1 in 4, or one fourth. The chances of landing on red are 1 in 4, or one fourth.
  • 6. 9/22/2018 6 SBE 304: Probability A Probabilistic Model for an Experiment Definition Example An experiment is a situation involving chance or probability that leads to results called outcomes. It is the process by which an observation is made In the problem above, the experiment is spinning the spinner. An outcome is the result of a single trial of an experiment. The possible outcomes are landing on yellow, blue, green or red. An event is one or more outcomes of an experiment. One event of this experiment is landing on blue. Probability is the measure of how likely an event is. The probability of landing on blue is one fourth. Cont. SBE 304: Probability The Probability of an Event Probability Of An Event P(A) = The Number Of Ways Event A Can Occur The total number Of Possible Outcomes The probability of event A is the number of ways event A can occur divided by the total number of possible outcomes.
  • 7. 9/22/2018 7 SBE 304: Probability The Probability of an Event A spinner has 4 equal sectors colored yellow, blue, green and red. After spinning the spinner, what is the probability of landing on each color? Experiment Outcomes The possible outcomes of this experiment are yellow, blue, green, and red Cont. SBE 304: Probability Probabilities P(yellow) = # of ways to land on yellow total # of colors = 1 4 P(blue) = # of ways to land on blue total # of colors = 1 4 P(green) = # of ways to land on green total # of colors = 1 4 P(red) = # of ways to land on red total # of colors = 1 4 Cont. The Probability of an Event
  • 8. 9/22/2018 8 SBE 304: Probability A single 6-sided die is rolled. What is the probability of each outcome? What is the probability of rolling an even number? of rolling an odd number? Experiment Outcomes The possible outcomes of this experiment are 1, 2, 3, 4, 5 and 6. Cont. The Probability of an Event SBE 304: Probability P(3) = # of ways to roll a 3 total # of sides = 1 6 P(even) = # ways to roll an even number total # of sides = 3 6 = 1 2 P(odd) = # ways to roll an odd number total # of sides = 3 6 = 1 2 Probabilities Cont. The Probability of an Event
  • 9. 9/22/2018 9 SBE 304: Probability Theory of Probability A set of all possible outcomes. It is usually denoted by S The Sample Space A Discrete Sample Space It contains either a finite or a countable number of distinct sample points/events. SBE 304: Probability Event Probability A not A A and B A or B A given B The Multiplicative Law The Additive Law Bayes’ Rule Cont. Theory of Probability
  • 10. 9/22/2018 10 SBE 304: Probability P(A ∩ B) = The Number Of Ways Event A ∩ B Can Occur The total number Of Possible Outcomes P(A|B) = P(A∩ B)/P(B) The Number Of Ways Event A ∩ B Can Occur The Number Of Ways Event B Can Occur P(B) = The Number Of Ways Event B Can Occur The total number Of Possible Outcomes Note: P(A|B)P(B) = P(A∩ B) = P(B|A)P(A) Cont. Theory of Probability SBE 304: Probability  P(A|B) = P(A∩B) / P(B)  P(B|A) = P(B∩A) / P(A)  P(A∩B) = P(A|B) P(B)  P(B|A) P(A) = P(A∩B) = P(A|B) P(B)  P(B|A) = P(A|B) P(B) / P(A)  P(B|A) = P(A|B)P(B) / (P(A|B)P(B) + P(A|B‘)P(B‘)) ? Cont. Theory of Probability
  • 11. 9/22/2018 11 SBE 304: Probability  B∪B‘ = Ω, the universal event.  B∩B‘ = Φ, an empty event.  A = A ∩ (B ∪ B‘)  A = A∩B ∪ A∩B‘ since A∩B and A∩B ‘ are mutually exclusive  P(A) = P(A∩B ∪ A∩B ‘)  P(A) = P(A∩B) + P(A∩B ‘)  P(A) = P(A|B)P(B) + P(A|B ‘)P(B ‘) Cont. Theory of Probability SBE 304: Probability  A doctor is called to see a sick child. The doctor has prior information that 90% of sick children in that neighborhood have the flu, while the other 10% are sick with measles. Let F stand for an event of a child being sick with flu and M stand for an event of a child being sick with measles. Assume for simplicity that F ∪ M = Ω, i.e., that there no other maladies in that neighborhood.  A well-known symptom of measles is a rash (the event of having which we denote R). P(R|M) = .95. However, occasionally children with flu also develop rash, so that P(R|F) = 0.08.  Upon examining the child, the doctor finds a rash. What is the probability that the child has measles?. Example I Cont. Theory of Probability
  • 12. 9/22/2018 12 SBE 304: Probability  P(M|R) = .95 × .10 / (.95 × .10 + .08 × .90)  P(M|R) ≈ 0.57 Solution I Cont. Theory of Probability P(R|M) P(M) / (P(R|M) P(M) + P(R|F) P(F)) P(M|R) = SBE 304: Probability  In a study, physicians were asked what the odds of breast cancer would be in a woman who was initially thought to have a 1% risk of cancer but who ended up with a positive mammogram result (a mammogram accurately classifies about 80% of cancerous tumors and 90% of benign tumors.)  95 out of a hundred physicians estimated the probability of cancer to be about 75%. Do you agree? Example II Introduce the events: P - mammogram result is positive, B - tumor is benign, M - tumor is malignant. Cont. Theory of Probability
  • 13. 9/22/2018 13 SBE 304: Probability Introduce the events: P - mammogram result is positive, B - tumor is benign, M - tumor is malignant. Bayes' formula in this case is P(M|P) = P(P|M) P(M) / (P(P|M) P(M) + P(P|B) P(B)) = .80 × .01 / (.80 × .01 + .10 × .99) ≈ 0.075 ≈ 7.5%. A far cry from a common estimate of 75%. Solution II Cont. Theory of Probability SBE 304: Probability Calculating the Probability of an Event I. Define the experiment. II. List all the simple outcomes associated with the experiment. These outcomes constitute the sample space. III. Assign reasonable probabilities to these outcomes. Make sure each probability is greater than or equal to zero and the sum of the probabilities is 1. If all outcomes are equally likely the probability of each will be 1/n. IV. Define the event of interest A and see the outcomes in the sample space which makes A occur. V. Find P(A) by adding the probabilities of these outcomes which make A occur.
  • 14. 9/22/2018 14 SBE 304: Probability  If the sample space contains a very large number of sample points, complete itemization will be tedious, time consuming and might be practically impossible.  When this occurs we need not list the points but just use combinatorial analysis to know the number of points in the sample space (N) and the event space (n).  If outcomes are equally likely the probability of the event is n/N. Notes: Cont. Calculating the Probability of an Event SBE 304: Probability P(A ∪ B ∪ C) = P((A ∪ B) ∪ C) = P(A ∪ B) + P(C) – P((A ∪ B) ∩ C) = P(A) + P(B) – P(A ∩ B) + P(C) – P((A ∩ C) ∪ (B ∩ C)) = P(A) + P(B) + P(C) – P(A ∩ B) -[P(A ∩ C) + P(B ∩ C) – P(A ∩B ∩ C)] = P(A) + P(B) + P(C) – P(A ∩ B) - P(A ∩ C) - P(B ∩ C) + P(A ∩B ∩ C) Three or More Events Cont. Calculating the Probability of an Event  P(A ∪ B) = P(A) + P(B) – P(A ∩ B)
  • 15. 9/22/2018 15 SBE 304: Probability  A collection of events, E1, E2, …Ek, is said to be mutually exclusive for all pairs: Ei ∩ Ej = Φ, an empty event Three or More Events For a collection of mutually exclusive events, P(E1 ∪ E2 ∪ ….. ∪ Ek) = P(E1) + P(E2) + …… + P(Ek) Cont. Calculating the Probability of an Event SBE 304: Probability  P(A) = P(A∩B) + P(A∩B ‘)  P(A) = P(A|B)P(B) + P(A|B ‘)P(B ‘)  In general, a collection of mutually exclusive sets, E1, E2, …Ek, such that E1 ∪ E2 ∪ ….. ∪ Ek = S, is said to be exhaustive.  P(A) = P(A∩E1) + P(A∩E2) + ….. P(A ∩ Ek)  P(A) = P(A| E1)P(E1) + P(A| E2)P(E2) + ….. + P(A| Ek)P(Ek)  P(Ej| A) = P(A| Ej)P(Ej) / ∑ P(A| Ei)P(Ei) {i=1,2, ….,k)} Three or More Events Total Probability Rule Cont. Calculating the Probability of an Event
  • 16. 9/22/2018 16 SBE 304: Probability Tools for counting sample points/events Multiplication of Choices With m elements a1, a2, ….., am and n elements b1, b2, ….., bn, it is possible to form mn = m * n pairs containing one element from each group SBE 304: Probability Multiplication of Choices Example: There are seven different trails to the top of the mountain. In how many different ways can a person hike up and down the mountain if 1.he must take the same trail both ways; 2.he can, but need not, take the same trail both ways; 3.he does not want to take the same trail both ways. 7 * 7 7 * 6 7 Cont. Tools for counting sample points/events
  • 17. 9/22/2018 17 SBE 304: Probability Permutation An ordered arrangement of r distinct objects is called a permutation (n!). The number of ways of ordering n distinct objects taken r at a time will be designed by the symbol Pr n Pr n = n(n - 1)(n - 2)…..(n – r + 1) = n! / (n - r)! Tools for counting sample points/events Cont. SBE 304: Probability Permutation Consider a set of elements, such as S {a, b, c}. A permutation of the elements is an ordered sequence of the elements. For example, abc, acb, bac, bca, cab, and cba are all of the permutations of the elements of S. Example: n! = n(n - 1)(n - 2)…..(1) 3! = 3 * 2 * 1 = 6 Cont. Tools for counting sample points/events
  • 18. 9/22/2018 18 SBE 304: Probability Permutation A printed circuit board has eight different locations in which a component can be placed. If four different components are to be placed on the board, how many different designs are possible? Example: Each design consists of selecting a location from the eight locations for the first component, a location from the remaining seven for the second component, a location from the remaining six for the third component, and a location from the remaining five for the fourth component. Therefore, P4 8 = 8*7*6*5= 8! / (8 - 4)! = 1680 1680 different designs are possible. Cont. Tools for counting sample points/events SBE 304: Probability Partitioning n distinct objects into k distinct groups The number of ways N of partitioning n distinct objects into k distinct groups containing n1, n2, ….., nk, objects, respectively, where each object appears in exactly one group and ∑ ni = n, where i=1, 2, ….., k, is N = ( )n n1 n2 ….. nk = ________________ n! n1! n2! ….. nk! Tools for counting sample points/events Cont.
  • 19. 9/22/2018 19 SBE 304: Probability Partitioning n distinct objects into k distinct groups A part is labeled by printing with four thick lines, three medium lines, and two thin lines. If each ordering of the nine lines represents a different label, how many different labels can be generated by using this scheme? Example: ( )N = n n1 n2 ….. nk = ________________ n! n1! n2! ….. nk! = 9!/4!3!2! Cont. Tools for counting sample points/events SBE 304: Probability Combinations The number of unordered subsets of size r chosen (without replacement) from n available objects is ( )n r = C n r = ________________ n! r! (n – r)! Cont. Tools for counting sample points/events
  • 20. 9/22/2018 20 SBE 304: Probability Combinations Consider the problem of choosing two patient monitoring systems for ICU out of a group of five and imagine that the monitoring systems vary in competence, 1 being the best, 2 second best, and so on, for 3, 4, and 5. These rating are of course unknown to the nurse. A- Find the number of ways of selecting two systems out of five. B- Let A denote the event that exactly one of the two best systems appears in a selection of two out of five. Find the number of sample points in A and P(A). Example: (5 2) = 5!/2!3! = 10 n = (2 1) (3 1) = 2*3=6 P(A) = 0.6 Cont. Tools for counting sample points/events SBE 304: Probability When male and female workers become sick, what do they do? A survey was carried out and the responses of 500 workers were tabulated Example: Action Male (M) Female Consult a doctor (D) 115 70 Consult a pharmacist for a pain killer medication 60 140 Go to a hospital 75 40 1. What is the probability that a man would consult a pharmacist? 2. What proportion of workers consults a doctor? 3. If a worker is known to be a female, what is the probability that she will go to a hospital? 4. Among workers consulting a pharmacist, what proportion are males? 5. Are gender and consulting a doctor independent? Verify your answer. Dependent: P(D) ≠ P(D|M) 60/200 = 0.3 60/500 = 0.12 185/500 = 0.37 40/250 = 0.16
  • 21. 9/22/2018 21 SBE 304: Probability Characterizing a set of Measurements The Mean The mean of a sample of n measured responses y1, y2, ….., yn is given by Y = __ ___1 n ∑ n i = 1 yiµ = SBE 304: Probability Characterizing a set of Measurements The Variance The variance of a sample of measurements y1, y2, ….., yn is the sum of the differences between the measurements and their mean, divided by n – 1. S2 = _______1 n - 1 ∑ n i = 1 (yi – µ)2 σ 2 =
  • 22. 9/22/2018 22 SBE 304: Probability Characterizing a set of Measurements The standard deviation The standard deviation of a sample of measurements is the positive square root of the variance; that is, S = S2 = σ 2 = σ SBE 304: Probability Characterizing a set of Measurements Graphical Methods – Frequency Histogram A frequency distribution is a tabulation of the values that one or more variables take in a sample. Each entry in the table contains the frequency or count of the occurrences of values within a particular group or interval, and in this way the table summarizes the distribution of values in the sample. Rank Degree of agreement Number 1 Strongly agree 20 2 Agree somewhat 30 3 Not sure 20 4 Disagree somewhat 15 5 Strongly disagree 15
  • 23. 9/22/2018 23 SBE 304: Probability Characterizing a set of Measurements Graphical Methods – Frequency Histogram 0 5 10 15 20 25 30 35 Strongly agree Agree somewhat Not sure Disagree somewhat Strongly disagree 1 2 3 4 5 Number Number g{tÇ~ lÉâg{tÇ~ lÉâg{tÇ~ lÉâg{tÇ~ lÉâ