Basic Probability Robert Platt Northeastern University Some images - - PowerPoint PPT Presentation

basic probability
SMART_READER_LITE
LIVE PREVIEW

Basic Probability Robert Platt Northeastern University Some images - - PowerPoint PPT Presentation

Basic Probability Robert Platt Northeastern University Some images and slides are used from: 1. CS188 UC Berkeley 2. RN, AIMA Definition Probability theory is nothing but common sense reduced to calculation. ~Pierre Laplace What is


slide-1
SLIDE 1

Basic Probability

Robert Platt Northeastern University Some images and slides are used from:

  • 1. CS188 UC Berkeley
  • 2. RN, AIMA
slide-2
SLIDE 2

Definition

  • Probability theory is nothing but common sense

reduced to calculation. ~Pierre Laplace

  • What is probability? What does it mean when

we say “the probability that a coin will land head is 0.5”

slide-3
SLIDE 3

Frequentist Vs Bayesian

slide-4
SLIDE 4

Random variables

What is a random variable? Suppose that the variable a denotes the outcome of a role of a single six-sided die: a is a random variable this is the domain of a Another example: Suppose b denotes whether it is raining or clear outside:

slide-5
SLIDE 5

Probability distribution

A probability distribution associates each with a probability of occurrence. A probability table is one way to encode the distribution: All probability distributions must satisfy the following: 1. 2.

slide-6
SLIDE 6

Writing probabilities

For example: But, sometimes we will abbreviate this as:

slide-7
SLIDE 7

Joint probability distributions

Given random variables: The joint distribution is a probability assignment to all combinations: As with single-variate distributions, joint distributions must satisfy:

  • r:

1. 2.

slide-8
SLIDE 8

Joint probability distributions

Joint distributions are typically written in table form:

slide-9
SLIDE 9

Marginalization

Given P(T,W), calculate P(T) or P(W)...

slide-10
SLIDE 10

Marginalization

Slide: Berkeley CS188 course notes (downloaded Summer 2015)

X Y P +x +y 0.2 +x

  • y

0.3

  • x

+y 0.4

  • x
  • y

0.1 X P +x

  • x

Y P +y

  • y
slide-11
SLIDE 11

Conditional Probabilities

Probability that it is sunny given that it is hot.

slide-12
SLIDE 12

Conditional Probabilities

Slide: Berkeley CS188 course notes (downloaded Summer 2015)

Product rule Calculate the conditional probability using the product rule:

slide-13
SLIDE 13

Conditional Probabilities

Slide: Berkeley CS188 course notes (downloaded Summer 2015)

X Y P +x +y 0.2 +x

  • y

0.3

  • x

+y 0.4

  • x
  • y

0.1

  • P(+x | +y) ?
  • P(-x | +y) ?
  • P(-y | +x) ?
slide-14
SLIDE 14

Conditional distribution

Given P(T,W), calculate P(T|w) or P(W|t)...

slide-15
SLIDE 15

Conditional distribution

Given P(T,W), calculate P(T|w) or P(W|t)...

slide-16
SLIDE 16

Conditional distribution

Given P(T,W), calculate P(T|w) or P(W|t)...

slide-17
SLIDE 17

Conditional distribution

Given P(T,W), calculate P(T|w) or P(W|t)...

slide-18
SLIDE 18

Normalization

Given P(T,W), calculate P(T|w) or P(W|t)...

Can we avoid explicitly computing this?

slide-19
SLIDE 19

Normalization

Select corresponding elts from the joint distribution Scale the numbers so that they sum to 1.

slide-20
SLIDE 20

Normalization

Select corresponding elts from the joint distribution Scale the numbers so that they sum to 1. The only purpose of this denominator is to make the distribution sum to one. – we achieve the same thing by scaling.

slide-21
SLIDE 21

Normalization

X Y P +x +y 0.2 +x

  • y

0.3

  • x

+y 0.4

  • x
  • y

0.1

P(X | Y=-y) ? ? ?

slide-22
SLIDE 22

Bayes Rule

slide-23
SLIDE 23

Bayes Rule

It's easy to derive from the product rule: Solve for this

slide-24
SLIDE 24

Using Bayes Rule

slide-25
SLIDE 25

Using Bayes Rule

It's often easier to estimate this But harder to estimate this

slide-26
SLIDE 26

Bayes Rule Example

meningitis Suppose you have a stiff neck... Suppose there is a 70% chance of meningitis if you have a stiff neck: Suppose you have a stiff neck... stiff neck What are the chances that you have meningitis?

slide-27
SLIDE 27

Bayes Rule Example

meningitis Suppose you have a stiff neck... Suppose there is a 70% chance of meningitis if you have a stiff neck: Suppose you have a stiff neck... stiff neck What are the chances that you have meningitis? We need a little more information...

slide-28
SLIDE 28

Bayes Rule Example

Prior probability of meningitis Prior probability of stiff neck

slide-29
SLIDE 29

Bayes Rule Example

Prior probability of meningitis Prior probability of stiff neck

slide-30
SLIDE 30

Bayes Rule Example

  • Given:
  • What is P(W | dry) ?

R P sun 0.8 rain 0.2 D W P wet sun 0.1 dry sun 0.9 wet rain 0.7 dry rain 0.3

Slide: Berkeley CS188 course notes (downloaded Summer 2015)