Today. Next lecture. (Ch 14) Markov chains and hidden Markov models

Similar documents
Data and Algorithms of the Web

Uncertainty and Randomization

Lab 8: Measuring Graph Centrality - PageRank. Monday, November 5 CompSci 531, Fall 2018

18.600: Lecture 32 Markov Chains

Link Analysis. Stony Brook University CSE545, Fall 2016

Lecture 6: Entropy Rate

Lesson Plan. AM 121: Introduction to Optimization Models and Methods. Lecture 17: Markov Chains. Yiling Chen SEAS. Stochastic process Markov Chains

0.1 Naive formulation of PageRank

Statistical Problem. . We may have an underlying evolving system. (new state) = f(old state, noise) Input data: series of observations X 1, X 2 X t

CS246: Mining Massive Datasets Jure Leskovec, Stanford University.

MATH3200, Lecture 31: Applications of Eigenvectors. Markov Chains and Chemical Reaction Systems

Lecture 5: Random Walks and Markov Chain

18.440: Lecture 33 Markov Chains

Lecture 5: Introduction to Markov Chains

Chapter 10. Finite-State Markov Chains. Introductory Example: Googling Markov Chains

CS246: Mining Massive Datasets Jure Leskovec, Stanford University

1998: enter Link Analysis

Some Definition and Example of Markov Chain

Link Mining PageRank. From Stanford C246

Google PageRank. Francesco Ricci Faculty of Computer Science Free University of Bozen-Bolzano

CS6220: DATA MINING TECHNIQUES

CS249: ADVANCED DATA MINING

Data Mining and Matrices

Please simplify your answers to the extent reasonable without a calculator. Show your work. Explain your answers, concisely.

COMS 4771 Probabilistic Reasoning via Graphical Models. Nakul Verma

PageRank. Ryan Tibshirani /36-662: Data Mining. January Optional reading: ESL 14.10

Introduction to Data Mining

Plan for today. ! Part 1: (Hidden) Markov models. ! Part 2: String matching and read mapping

Application. Stochastic Matrices and PageRank

Markov Processes Hamid R. Rabiee

18.175: Lecture 30 Markov chains

How works. or How linear algebra powers the search engine. M. Ram Murty, FRSC Queen s Research Chair Queen s University

Mathematical Methods for Computer Science

IR: Information Retrieval

CS168: The Modern Algorithmic Toolbox Lecture #14: Markov Chain Monte Carlo

Notes on Markov Networks

Part A. P (w 1 )P (w 2 w 1 )P (w 3 w 1 w 2 ) P (w M w 1 w 2 w M 1 ) P (w 1 )P (w 2 w 1 )P (w 3 w 2 ) P (w M w M 1 )

CS145: Probability & Computing Lecture 18: Discrete Markov Chains, Equilibrium Distributions

CS6220: DATA MINING TECHNIQUES

Markov Chains. Chapter 16. Markov Chains - 1

CS224W: Social and Information Network Analysis Jure Leskovec, Stanford University

A Note on Google s PageRank

Link Analysis. Reference: Introduction to Information Retrieval by C. Manning, P. Raghavan, H. Schutze

= P{X 0. = i} (1) If the MC has stationary transition probabilities then, = i} = P{X n+1

MATH36001 Perron Frobenius Theory 2015

Lecture 15: MCMC Sanjeev Arora Elad Hazan. COS 402 Machine Learning and Artificial Intelligence Fall 2016

Markov Chains (Part 4)

ECEN 689 Special Topics in Data Science for Communications Networks

COMPSCI 514: Algorithms for Data Science

Page rank computation HPC course project a.y

Probability & Computing

Markov Chains and MCMC

SDS 321: Introduction to Probability and Statistics

n(1 p i ) n 1 p i = 1 3 i=1 E(X i p = p i )P(p = p i ) = 1 3 p i = n 3 (p 1 + p 2 + p 3 ). p i i=1 P(X i = 1 p = p i )P(p = p i ) = p1+p2+p3

The Theory behind PageRank

Online Social Networks and Media. Link Analysis and Web Search

Slide source: Mining of Massive Datasets Jure Leskovec, Anand Rajaraman, Jeff Ullman Stanford University.

Graph Models The PageRank Algorithm

Updating PageRank. Amy Langville Carl Meyer

ISE/OR 760 Applied Stochastic Modeling

No class on Thursday, October 1. No office hours on Tuesday, September 29 and Thursday, October 1.

MAS275 Probability Modelling Exercises

Lecture 20 : Markov Chains

DATA MINING LECTURE 13. Link Analysis Ranking PageRank -- Random walks HITS

Link Analysis. Leonid E. Zhukov

LTCC. Exercises. (1) Two possible weather conditions on any day: {rainy, sunny} (2) Tomorrow s weather depends only on today s weather

Homework set 2 - Solutions

Markov Chains. As part of Interdisciplinary Mathematical Modeling, By Warren Weckesser Copyright c 2006.

2 DISCRETE-TIME MARKOV CHAINS

CS325 Artificial Intelligence Ch. 15,20 Hidden Markov Models and Particle Filtering

Markov Chains and Stochastic Sampling

LEARNING DYNAMIC SYSTEMS: MARKOV MODELS

CS168: The Modern Algorithmic Toolbox Lecture #6: Markov Chain Monte Carlo

Markov Chains CK eqns Classes Hitting times Rec./trans. Strong Markov Stat. distr. Reversibility * Markov Chains

CS 188: Artificial Intelligence

Hidden Markov Models. Hosein Mohimani GHC7717

Slides based on those in:

Spectral Graph Theory and You: Matrix Tree Theorem and Centrality Metrics

Markov Chains, Random Walks on Graphs, and the Laplacian

Numerical methods for lattice field theory

Doing Physics with Random Numbers

CS345a: Data Mining Jure Leskovec and Anand Rajaraman Stanford University

Machine Learning for Data Science (CS4786) Lecture 24

Discrete Markov Chain. Theory and use

Web Ranking. Classification (manual, automatic) Link Analysis (today s lesson)

Online Social Networks and Media. Link Analysis and Web Search

Math 416 Lecture 3. The average or mean or expected value of x 1, x 2, x 3,..., x n is

ISyE 6650 Probabilistic Models Fall 2007

Lecture 12: Link Analysis for Web Retrieval

Data Mining Recitation Notes Week 3

Hidden Markov Models

eigenvalues, markov matrices, and the power method

2 Discrete-Time Markov Chains

INTRODUCTION TO MCMC AND PAGERANK. Eric Vigoda Georgia Tech. Lecture for CS 6505

2007 Winton. Empirical Distributions

Math 456: Mathematical Modeling. Tuesday, March 6th, 2018

SVD, Power method, and Planted Graph problems (+ eigenvalues of random matrices)

COMS 4721: Machine Learning for Data Science Lecture 20, 4/11/2017

Introduction to Search Engine Technology Introduction to Link Structure Analysis. Ronny Lempel Yahoo Labs, Haifa

CS 277: Data Mining. Mining Web Link Structure. CS 277: Data Mining Lectures Analyzing Web Link Structure Padhraic Smyth, UC Irvine

Transcription:

Today (Ch 14) Markov chains and hidden Markov models Graphical representation Transition probability matrix Propagating state distributions The stationary distribution Next lecture (Ch 14) Markov chains and hidden Markov models Hidden Markov models Viterbi algorithm

Complete the sentence I had a glass of red wine with my grilled

Describing a sequence with a Markov chain Let XX 0, XX 1, be a sequence of discrete finite-valued random variables The sequence is a Markov chain if the probability of the current value XX tt only depends on the previous value XX tt 1 PP XX tt XX 1,, XX tt 1 = PP(XX tt XX tt 1 ) Also assume that the transition probabilities do not change with time PP XX tt XX tt 1 = PP XX tt 1 XX tt 2 = = PP(XX 1 XX 0 )

Markov chain: coin example Toss a fair coin until you see two heads in a row and then stop What is the probability of stopping after exactly 2 flips? What is the probability of stopping after exactly 3 flips? What is the probability of stopping after exactly 4 flips?

Markov chain as a graph: coin example

Forming a recurrence relation: coin example Let pp nn be the probability of stopping after exactly nn flips We already know that pp 1 = 0, pp 2 = 1 4, pp 3 = 1 8, pp 4 = If nn > 2, there are two ways the sequence can start Toss T and then end in exactly nn 1 tosses Toss HT and then end in exactly nn 2 tosses So we derive a recurrence relation 1 8 pp nn = 1 2 pp nn 1 + 1 4 pp nn 2

Transition probability matrix: weather example Let s model daily weather as one of three states (sunny, rainy, snowy) with transition probabilities shown in the diagram below These probabilities can be represented in a transition probability matrix

Transition probability matrix properties The transition probability matrix PP is a square matrix with entries pp iiii Since pp iiii = PP XX tt = jj XX tt 1 = ii pp iiii 0 and pp iiii = 1 jj

Probability distributions over states Let ππ be a row vector containing the probability distribution over states at tt = 0 ππ ii = PP(XX 0 = ii) Example: suppose that it is rainy today; then ππ = 0 1 0 Let pp (tt) be a row vector containing the probability distribution over states at tt pp ii (tt) = PP(XXtt = ii)

Propagating the probability distribution Propagating from tt = 0 to tt = 1, (1) pp jj = PP XX1 = jj = ii PP XX 1 = jj, XX 0 = ii = ii PP XX 1 = jj, XX 0 = ii PP(XX 0 = ii) = ii pp iiii ππ ii In matrix notation, pp (1) = ππpp

Probability distributions: weather example Suppose that it is rainy today, so we know that ππ = 0 1 0 What are the probability distributions for the weather tomorrow and the next day? 0.7 0.2 0.1 pp (1) = ππpp = 0 1 0 0.2 0.6 0.2 = 0.2 0.6 0.2 0.4 0.1 0.5 pp (2) = pp (1) PP = 0.2 0.6 0.2 0.7 0.2 0.1 0.2 0.6 0.2 0.4 0.1 0.5 = 0.28 0.40 0.32

Propagating to tt = We have just seen that pp (2) = pp (1) PP = ππpp PP = ππpp 2 In general pp (tt) = ππpp tt If you can reach any state from any other state, the Markov chain is called irreducible and has the following property lim tt ππpptt = ss where is ss called the stationary distribution of the Markov chain

Stationary distribution The stationary distribution ss has the property that sspp = ss In other words, ss is a row eigenvector of PP with eigenvalue of 1 Example: regardless of the initial probability distribution ππ, the stationary distribution for our daily weather model is ss = lim tt ππ 0.7 0.2 0.1 0.2 0.6 0.2 0.4 0.1 0.5 tt = 18 37 11 37 8 37

The billion dollar eigenvector

Randomly surfing a network of webpages

Initialize the distribution uniformly

Update the distribution iteratively...

until the stationary distribution is reached

Sometimes the surfer gets trapped

The teleportation fix The PageRank algorithm avoids the problem of getting trapped in a subnetwork of pages by allowing the web surfer to teleport from any webpage to any other with small probability Teleportation corresponds to entering a URL directly into the browser