WXML Final Report: Chinese Restaurant Process

Similar documents
CS281B / Stat 241B : Statistical Learning Theory Lecture: #22 on 19 Apr Dirichlet Process I

URN MODELS: the Ewens Sampling Lemma

De los ejercicios de abajo (sacados del libro de Georgii, Stochastics) se proponen los siguientes:

Erdős-Renyi random graphs basics

3. The Voter Model. David Aldous. June 20, 2012

Stochastic Processes, Kernel Regression, Infinite Mixture Models

Research Statement Noah Forman 2018

Elementary Applications of Probability Theory

Inventory Model (Karlin and Taylor, Sec. 2.3)

Recap. Probability, stochastic processes, Markov chains. ELEC-C7210 Modeling and analysis of communication networks

2. Transience and Recurrence

Microevolution Changing Allele Frequencies

Lecture 19 : Chinese restaurant process

LogFeller et Ray Knight

Evolution in a spatial continuum

Dynamics of the evolving Bolthausen-Sznitman coalescent. by Jason Schweinsberg University of California at San Diego.

19. Genetic Drift. The biological context. There are four basic consequences of genetic drift:

Biology 11 UNIT 1: EVOLUTION LESSON 2: HOW EVOLUTION?? (MICRO-EVOLUTION AND POPULATIONS)

BRANCHING PROCESSES 1. GALTON-WATSON PROCESSES

Evolution & Natural Selection

How robust are the predictions of the W-F Model?

Random trees and branching processes

Abstract These lecture notes are largely based on Jim Pitman s textbook Combinatorial Stochastic Processes, Bertoin s textbook Random fragmentation

(b) What is the variance of the time until the second customer arrives, starting empty, assuming that we measure time in minutes?

How to Use This Presentation

An Infinite Product of Sparse Chinese Restaurant Processes

Modern Discrete Probability Branching processes

Statistics 253/317 Introduction to Probability Models. Winter Midterm Exam Monday, Feb 10, 2014

Population Genetics & Evolution

Probability, Random Processes and Inference

Macroscopic quasi-stationary distribution and microscopic particle systems

Lecture 4a: Continuous-Time Markov Chain Models

Matthew Rathkey, Roy Wiggins, and Chelsea Yost. May 27, 2013

Continuous-time Markov Chains

Stability and Rare Events in Stochastic Models Sergey Foss Heriot-Watt University, Edinburgh and Institute of Mathematics, Novosibirsk

Bayesian Nonparametrics: Models Based on the Dirichlet Process

The Contour Process of Crump-Mode-Jagers Branching Processes

19 : Bayesian Nonparametrics: The Indian Buffet Process. 1 Latent Variable Models and the Indian Buffet Process

The strictly 1/2-stable example

Computational statistics

Branching Processes II: Convergence of critical branching to Feller s CSB

Computational Systems Biology: Biology X

Frequency Spectra and Inference in Population Genetics

Foundations of Nonparametric Bayesian Methods

Figure 10.1: Recording when the event E occurs

Part I Stochastic variables and Markov chains

The Wright-Fisher Model and Genetic Drift

Introduction to population genetics & evolution

Problems on Evolutionary dynamics

Feature Allocations, Probability Functions, and Paintboxes

The exponential distribution and the Poisson process

Reinforcement Learning: Part 3 Evolution

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

An ergodic theorem for partially exchangeable random partitions

Chapter 8: Introduction to Evolutionary Computation

Bayesian Nonparametrics: Dirichlet Process

Application: Bucket Sort

Markov Chains. X(t) is a Markov Process if, for arbitrary times t 1 < t 2 <... < t k < t k+1. If X(t) is discrete-valued. If X(t) is continuous-valued

Exponential Distribution and Poisson Process

The Boundary Problem: Markov Chain Solution

So in terms of conditional probability densities, we have by differentiating this relationship:

The story of the film so far... Mathematics for Informatics 4a. Continuous-time Markov processes. Counting processes

Math 105 Exit Exam Review

Chapter 4a Probability Models

CASE STUDY: EXTINCTION OF FAMILY NAMES

Scribe Notes 11/30/07

Ancestor Problem for Branching Trees

Other Organisms (Part 3)

Lecture 16-17: Bayesian Nonparametrics I. STAT 6474 Instructor: Hongxiao Zhu

Genetic Algorithms. Donald Richards Penn State University

EVOLUTION change in populations over time

Probabilistic Graphical Models

3-LS1-1 From Molecules to Organisms: Structures and Processes

Other properties of M M 1

Bayesian Nonparametrics for Speech and Signal Processing

4 Branching Processes

Poisson Processes. Stochastic Processes. Feb UC3M

Mixing Times and Hitting Times

Model Building: Selected Case Studies

Non-Parametric Bayes

Data analysis and stochastic modeling

Bayesian Nonparametric Models

Advanced Machine Learning

An Introduction to Stochastic Modeling

Lecture 3a: Dirichlet processes

Discrete random structures whose limits are described by a PDE: 3 open problems

Problems for 3505 (2011)

Lecture 7: Simulation of Markov Processes. Pasi Lassila Department of Communications and Networking

HOMOGENEOUS CUT-AND-PASTE PROCESSES

27 : Distributed Monte Carlo Markov Chain. 1 Recap of MCMC and Naive Parallel Gibbs Sampling

Outline. Binomial, Multinomial, Normal, Beta, Dirichlet. Posterior mean, MAP, credible interval, posterior distribution

Statistics 246 Spring 2006

Introduction. Probability and distributions

Continuous-Time Markov Chain

NOTES Ch 17: Genes and. Variation

Final Exam: Probability Theory (ANSWERS)

Evidence: Table 1: Group Forkbird Population Data 1-Tined Forkbirds 2-Tined Forkbirds 4-Tined Forkbirds Initial

EXCHANGEABLE COALESCENTS. Jean BERTOIN

Bayesian Nonparametrics: some contributions to construction and properties of prior distributions

Lecture 20 : Markov Chains

Transcription:

WXML Final Report: Chinese Restaurant Process Dr. Noah Forman, Gerandy Brito, Alex Forney, Yiruey Chou, Chengning Li Spring 2017 1 Introduction The Chinese Restaurant Process (CRP) generates random partitions of the natural numbers and has applications in clustering algorithms in machine learning and in biological modeling. The first goal of this project is to learn about stochastic branching processes, the CRP, and the ordered CRP with reseating. The second goal is to program a simulation to generate images and an animation of a surprising visual representation of the ordered CRP with reseating. 2 Theory 2.1 Exchangeability 2.1.1 Polya s Urn We begin our investigation by considering Polya s urn model. Imagine that we have an urn containing n colored balls, k of which are green and n k are blue. We can see that the probability of randomly selecting a green ball from the urn is k/n and the probability of randomly selecting a blue ball is (n k)/n. After actually randomly choosing a ball, we observe its color, put the ball back into the urn, and also put another ball of the same color into the urn. This process is then repeated. 1

Consider an example in which we draw three green balls and then two blue balls from the urn (we will denote such a draw sequence as GGGBBB). It is easily shown that the probability of obtaining such a sequence is ( 1 2 ) ( 2 3 ) ( 3 4 ) ( 1 5 ) ( 2 6 ) = 1 60. Now, consider another draw sequence with the same number of green balls and blue balls, GBGBG. The probability of obtaining this sequence is ( ) ( ) ( ) ( ) ( ) 1 1 2 2 3 = 1 2 3 4 5 6 60. Surprisingly, these probabilities are the same. In fact, Polya s urn model is exchangeable. This means that the probability of any particular sequence with k green balls and n k blue balls is k! (n k)!. (n + 1)! One can ask whether the percentage of green draws out of the total number of draws converges to some number. To answer this question, we call upon the following theorem: Theorem (de Finetti). The probability distribution of any infinite exchangeable sequence of Bernoulli random variables is a mixture of the probability distributions of independent and identically distributed sequences of Bernoulli random variables. A consequence of the theorem is that the limit of the percentage of green draws does indeed converge. In fact, this percentage is actually random with uniform [0, 1] distribution. 2.1.2 Chinese Restaurant Process We now consider a model much like Polya s urn, the Chinese Restaurant Process. To set the stage, imagine that we have a Chinese restaurant that has infinitely many tables that can each seat infinitely many customers. When a new customer, say the nth, enters the restaurant, the probability of them sitting at a table with m other customers is m/n, and the probability of this nth customer sitting alone at a new table is 1/n. This seating rule can be visualized in the following example where n = 5: 2

Probabilities of customer 5 joining each table 2 3 1 3/5 1/5 1/5 4 It turns out that this process is also exchangeable. Specifically, the probability of having a particular seating configuration is not affected by seating order. One can see this demonstrated in the following example. Suppose that we have a sequence of 7 customers who sit at 5 tables in the order 1 1 1 2 2 3 4. The probability of obtaining this sequence is ( ) ( ) ( ) ( ) ( ) ( ) 1 2 1 1 1 1 (1) = 1 2 3 4 5 6 7 168. Alternatively, consider the same scenario with the sequence 1 2 3 4 1 2 1, which has the probability ( ) ( ) ( ) ( ) ( ) ( ) 1 1 1 1 1 2 (1) = 1 2 3 4 5 6 7 168. We can generalize this formulation of the CRP. Specifically, we can introduce a two parameter (α, θ)-chinese Restaurant Process, for α, θ R. These parameters, α and θ, are used in determining new seating rules. In this new formulation, the nth customer entering a restaurant with k non-empty tables will sit at a table with m customers with probability and will sit alone with probability m α n 1 + θ θ + kα n 1 + θ. We will make the restrictions that α [0, 1) and θ > α in order to avoid negative probabilities and to keep our simulations interesting (cf. Section 3). The above seating rule can be visualized in the following example where n = 5 and k = 2: 3

Probabilities of customer 5 joining each table 3 α 4 + θ 1 α 4 + θ θ + 2α 4 + θ Notice that the initial formulation of the CRP had α = 0 and θ = 1. 2.2 Chinese Restaurant Process with Reseating As a further extension of the Chinese Restaurant Process, we now introduce reseating. As the name suggests, for a fixed number of customers in the restaurant, reseating involves a uniformly random customer leaving the restaurant, reentering, and being reseated according to the (α, θ)-crp seating rule. Specifically, each customer leaves the restaurant with rate 1. Notice that reseating allows for tables to die off. That is, it is possible for every customer sitting at a given table to leave (the red table above demonstrates this phenomenon). In fact, given a restaurant with n customers, its population will decrease with exponential rate n and increase with exponential rate n + θ. The individual table populations will evolve, too. A table in this restaurant with m people will also lose customers with exponential rate m α and gain customers with exponential rate m. In order to observe this birth-and-death cycle of tables, we want to keep track of each table. Hence, we will randomly order the tables from left to right. Additionally, rather than only allowing new tables to be born on the right side, we will allow for customers to sit at new tables at any point between two other tables, as shown in the following illustration: 4

2 α 3 α 3 α 1 α θ α α α α In fact, The limiting proportions of customers in the (α, θ)-crp, listed in ranked order, is a random monotone decreasing sequence of positive real numbers that sum to 1. We say it has Poisson-Dirichlet distribution with parameters (α, θ). In 2009, Leonid Petrov [1] described the limit of evolution of the ranked sequences of table sizes in the (α, θ)-crp with reseating. In 1981, Ethier and Kurtz [2] did this for α = 0. As we mentioned previously, one of the main goals of this project is to create a graphical representation of the CRP. This representation arises through what we will call scaffolding and spindles. The scaffolding (black lines above) is a real-valued cádlág process (spectrally positive Stable(3/2)) of negative drift (or compensation) and positive jumps, where the jump times are exponentially distributed with rate 1. The heights of the jumps are given by the lifespans of tables. The leftmost jump corresponds to the leftmost table, and so on. The spindles (colored portions above) are continuous, R + -valued excursions with lifetime equal to the jump height. This means that the vertical component corresponds to the lifespan of a given table in the restaurant, while the horizontal component corresponds to the population of the table at a given time. This graphical representation also gives us information about the distribution of the population of the restaurant, which is to say the table populations, at any given time. This comes through what we will call the skewer process. 5

For some y R, we get the level y skewer by drawing a line across the picture at y. Then, from left to right, we collect the cross-section of the spindles and slide these values together, as if on a skewer, to remove gaps. As the skewer moves up, the interval partition evolves continuously. The cross-section sizes shrink and grow, which corresponds to the table populations shrinking and growing. 2.2.1 Moran Model The Moran model is a stochastic process used in biological modeling. It describes how alleles change in some gene pool from generation to generation. In this model, the children choose their parent i.i.d.. The child will then inherit their parent s alleles. However, each child has some independent probability of mutating and adopting the alleles of some other parent that currently exists in the gene pool. This is to say that the child cannot mutate to a brand new genotype. In this model, we see genetic drift, where alleles become more and less common at random. There is a tendency, though, for common genes to stay common and uncommon genes to stay uncommon. The Moran Model is similar to the CRP with reseating. For example, the children in the Moran model select types like new customers in the CRP randomly select tables. Also, in both models we see the property that common types selfperpetuate. Finally, the limit of the CRP with α = 0 is close to the Miran model 6

with infinitely many types. One difference between the two, though, is that people choose tables one-by-one in the CRP, whereas all children choose their parents at once in the Moran model. Although mutation in the Moran model is similar to sitting alone in the CRP, there is always a chance to introduce a new table in the CRP, but the Moran model does not allow for the introduction of new genotypes. 2.3 Lévy Processes We now turn out attention to Poisson processes, which model a number of events happening over time. Consider the process (N(t), t 0) shown below: 3 y 2 1 2 4 6 8 Here, N(t) has Poisson distribution with rate tλ for some number λ. Then, tλ (tλ)k P{N(t) = k} = e. k! The interarrival times in this process are i.i.d., specifically exponentially distributed with rate λ. The Poisson process can be further generalized. As before, we have arrivals or hits with rate λ, but instead of jumping by 1, we have i.i.d. jump sizes according to some probability distribution Λ. The generalized Poisson process can be visualized below: x 7

y 2 2 4 6 8 x 2 4 We can also add Poisson processes. If (N(t), t 0) is a Poisson process with rate λ and (M(t), t 0) is a Poisson process with rate µ, then (N(t) + M(t), t 0) is a Poisson process with rate λ + µ. We have a slightly different result for generalized Poisson processes. If (N 1 (t), t 0) is a generalized Poisson process with rate λ 1 and jump distribution Λ 1 and (N 2 (t), t 0) is a generalized Poisson process with rate λ 2 and jump distribution Λ 2, then (N 1 (t) + N 2 (t), t 0) is a generalized Poisson process with rate λ 1 + λ 2 and jump distribution λ 1 Λ 2 + λ 2 Λ 1 λ 1 + λ 2. Now, consider an infinite series of generalized Poisson processes where jumps come faster and faster but jump sizes get really small. This gives rise to a Lévy process, which is a stochastic process on R n (for our purposes, just R) with stationary, independent, increments. This process can be thought of as a continuum analogue to random walks. In fact, there are only three behaviors of this process: 1. Poisson jumps 2. Brownian motion 3. (Deterministic) drift (and compensation ) The aforementioned scaffolding process is a certain Lévy process with downward drift (or compensation) and upward jumps. 8

2.4 Branching Processes As we mentioned in Section 2.2, the lifetime of a table in the (α, θ)-crp gives rise to a sort of birth-and-death chain. It turns out that this chain actually converges to the squared Bessel process with dimension 1, or BESQ( 1). Hence, our spindles are actually squared-bessel excursions. We finally turn our attention to the Galton-Watson process. The Galton-Watson process with offspring distribution µ, where µ is some probability distribution on nonnegative integers, serves as a way to model the extinction of certain populations (Francis Galton used it to model the death of family names). We start with some population, then at each time step, each individual dies and is replaced by a random number of offspring with distribution µ i.i.d.. The Galton-Watson process is significant to us because BESQ( 1) can be approximated by the Galton-Watson process with emigration rate 1. Since the graphical representation of our model is reliant on generating spindles, the Galton- Watson process gives us an easy way to simulate the birth-and-death chain of the tables in our Chinese Restaurant. 3 Simulation As we have mentioned, the ultimate goal of this project is to simulate the ordered CRP with reseating. So, we begin by attempting to simulate the three major components of our graphical representation: the scaffolding, the spindles, and the skewer. The end result of this simulation is an image such as the one below. (We also produced animated GIFs, but these could not be included in this report.) 9

3.1 Spindles Creating spindles amounts to simulating the Galton-Watson process until our initial population reaches 0. As discussed in Section 2.4, how we actually simulate the Galton-Watson process is important because we need our simulation to converge to BESQ( 1). So, for the distribution µ, we sample from the binomial distribution Bm(n, 1/2), where n is the current table population. For the emigration with rate 1, we sample from the Bernoulli distribution Ber(1/2). The new table population is then 2 Bm(n, 1/2) Ber(1/2), which gives us the desired 10

convergence to BESQ( 1). There is still an issue of an initial population, however. The initial table population should be 1, but this leads to an issue where the picture is not adequate because there is 50% chance that the table dies off in one time step. So, we choose an initial population of 100. This value is large enough to allow for large spindles to be created but also small enough that the spindles in the image appear to be generated from an initial population of 1. Some examples of carrying out this simulation can be seen below. The spindle colors are not significant; the colors are randomly chosen for the sake of making a better picture. Time 0 2000 4000 6000 8000 10000 Time 0 1000 2000 3000 4000 5000 Time 0 2000 4000 6000 8000 6000 4000 2000 0 2000 4000 6000 Population 2000 0 2000 Population 4000 2000 0 2000 4000 Population 3.2 Scaffolding In our preliminary simulations of spindles, we found that the average lifespan of a table was double its initial population. More specifically, a table with initial population 100 typically lasted for 200 time steps. Since the scaffolding is negative drift (or compensation) and positive jumps, we choose the slope of the negative drift to be 200 in order to cancel out the expected table lifespan. As mentioned in Section 2.2, the x-coordinates of the jumps are exponentially distributed with rate 1. In order to simulate the scaffolding, then, we start at the origin and sample from the exponential distribution Exp(1). We drift downward until reaching the random x-coordinate and then jump and repeat the drift. This process results in something looking like the image below. 11

3.3 Skewer The actual calculation of the skewer is rather simple. When we simulate a spindle, we store the beginning and ending y-values of the spindle as well as the table populations at each time step. So, to create the skewer, we fix some nonnegative y-value and check if it was between the start and end points of each spindle. If it is, then we calculate where the fixed y-value lands inside the spindle itself. We then access the table population at that time step and plot double this value (since the spindles are reflected horizontally over the center) on the skewer. We then repeat this process for each spindle that contains the y-value. 3.4 Pictures Combining all of these pieces, we were able to create nice visual representations of the ordered Chinese Restaurant Process with reseating. 12

13

References [1] L. Petrov. Two-parameter family of infinite-dimensional diffusions on the kingman simplex. Functional Analysis and Its Applications, 43(4):279 296, 2009. [2] S. Ethier and T. Kurtz. The infinitely-many-neutral-alleles diffusion model. Advances in Applied Probability, 13(3):429 452, 1981. 14