Professional Documents
Culture Documents
Lesson 2 - Basics of Probability Theory
Lesson 2 - Basics of Probability Theory
Basics of
Probability Theory
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Probability Distributions
What are they?
Probability Distributions
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Probability Distributions
Variables
• Can take different values
• the value that variable will take is deterministic.
• Governed by an order
• Or determined by other factors
• e.g.
• Time (thankfully deterministic – set order!)
else, tomorrow could be exam day!
• BMI = Weight/ (Height^2)
Can determine what BMI would be for given height and weight
• any other?
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Random variables
• Can take different values
• BUT the value is governed by a random mechanism
• Sampling a particular unit, e.g.
• Height/weight of a person (we are all different!)
• Weekly income of a family
• Complex combination of various uncertain factors, e.g.
• How will be the weather today?
• When will the bus arrive?
• Outcome of a match/exam?
• Return on investment
• Behaviour of a person
• … and so on….(almost everything we come across)
Random variables
• The Only way to understand the random variables is to assign probabilities to all possible
outcomes
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Notations - I
• Random variables are often denoted by letters, e.g. X, Y or Z, etc.
• Sometimes, small letters are used to denote the notional observed value.
For e.g.
• Y = y, indicates that the observed value of the random variable Y is y,
• Xi = xi , i= 1,…,n indicates that we have observed n random variables (say, heights of n
individuals) and the notional observed value of the ith random variable Xi is xi.
10
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Notations - II
• A general probability distribution may be represented as f(x) or p(x)
• Typically, f(x) is used for continuous distributions and p(x) for discrete.
• For discrete, p(x) indicates the probability of X taking a value x.
• For continuous, f(x) indicates the probability density of X taking a value x.
11
Rules of probability
• Always positive and between 0 and 1.
12
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
probability
sunny, overcast or
showery? 0.3
13
Measured in cm
Area under the
Random variable: height
curve =1
Can take many possible
values
Shows the
values the
0.04 variable
0.02 can take
Prob (height < 170) 0
= shaded area 150 170 190
Height
in cm
14
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Probability density
Measured in cm
0.04
Probability
distribution for the 0.02
height of a female 0
student?? 150 170 190
Height
in cm
15
16
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
17
Variance
18
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Normal distribution
• Symmetric bell shaped distribution. Symmetric about m (mean)
19
Normal distribution
Area between
+1s and -1s = 0.68
20
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Normal distribution
Area between
+2s and -2s = 0.95
21
Normal distribution
Area between
+3s and -3s = 0.997
22
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Normal distribution
23
Normal distribution
Two Normal distributions with different (shifted) means but the same standard deviation
24
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Normal distribution
Two Normal distributions with different standard deviations but the same means
25
26
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
27
28
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
• But other distributions are mostly not symmetric and often only applicable
if X takes values in a certain range (>0 or between 0 and 1, etc.)
29
Probability theory
30
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Probability theory
• Events – compliment, intersection, union and sample space
• Laws of probability
31
Probability theory
• Statistics is about decision making under uncertainty.
32
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Probability theory
• An event is a basic outcome of a trial or a random experiment.
• For e.g. Tossing a coin is a random experiment and each of the possible
outcomes - H or T - is an event.
33
34
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Probability theory
• Compliment of an event A is denoted by Ac.
• Intersection of events A and B is denoted by A ∩ B and is
defined as the outcome shared by both A and B.
• Union of events A and B is denoted by A ∪ B and is defined as the
outcome shared by either A or B or both.
• Null event denotes ’no outcome’ and is denoted by ϕ.
35
36
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Probability theory
• Sample space is denoted by Ω and is the collection of all events
possible for a given experiment.
• For toss of a coin, Ω = {H, T, ϕ}.
• For throw of a dice, Ω = {1,2,3,4,5,6,ϕ}.
37
38
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
39
40
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
• P(Ac) = 1 – ½ = ½.
41
Conditional probability
• The conditional probability of A given B is
P (A|B) = P (A ∩ B)
P(B)
42
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
• We can see that P(A|B) = ½ = P(A), that is, A and B are independent
events.
43
44
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
• For e.g.
• toss of coin (H/T),
• results of an experiment (success/failure), etc.
45
• E[X] = p
• Var[X] = p(1-p)
46
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
Binomial distribution
• What if we have n repeated experiments?
• We could model them as n independent Bernoulli random variables OR
• We could model the distribution of the total no. of successes out of n!
47
• E[X] = np
• Var[X] = np(1-p)
48
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
49
• E[X] = λ
• Var[X] = λ
50
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
• Exponential distribution is a continuous distribution and also has just one, the
rate, parameter (similar to Poisson).
51
• E[X] = 1/λ
• Var[X] = 1/ λ2
52
University of Auckland
STATS707 Computational Intro to Statistics Basics of Probability Theory
53
54
University of Auckland