2 min read

Time in Laplace's rule in the context of a "for all" problem

We are working with a sequence of independent binary events on a discrete time-scale, say seconds, with success probability π. Call this sequence of events Xt, t=1. For instance, Xt=1 if it rains at second t and 0 otherwise. For each positive integer m, define the “for all”''"-type variable

Ytm={1if Xt(m1)+1==Xtm=1,0otherwise.

For instance, the variable Yt60=1 if it rained during the entirety of the the tth minute. We can do the same thing for days, with m=86400, weeks (m=7×86400), and so on.

Each variable Ytm has its own success probability πm, with P(Xt=1)=π being the most refined probability. Suppose you choose an m, such as m=86400 for daily data, and decide on a uniform prior for πm. Then you can deduce the implied prior for u=πm, where m is another positive integer. The induced prior is p(u)=(m/m)um/m1, or a Beta(m/m,1) prior, as can be seen from the following manipulation P(Uu)=P(πmm/mu),=P(πmum/m),=um/m, with the the derivative being the induced prior p(u)=(m/m)um/m1=(m/m)um/m1. Then it is well known that the posterior p(u{Ytm}) is beta distributed with parameters

α=Sn+m/m,β=nSn+1, where Sn are the number of success in your data and n is the number of trials on the m scale.

Since the expectation of the a Beta(α,β) variable is α/(α+β), it follows that

E[Yn+1=1]=αα+β=Sn+m/mn+1+m/m, where m is the original time scaling and m is the new time scaling.

Rain example

Suppose our discrete time unit is seconds, and suppose it has rained every second for the last week. Assume a uniform prior on the probability for raining for a whole day. Then P(rains next dayrained every day last week)=7+17+1+1=89=0.888. Calculating on the hour scale instead, we find that m/m=24, that Sn=247 and n=247 P(rains next dayrained every day last week),=u24f(uSn+24,nSn+1)du,=r=0k1Sn+m/m+rn+1+m/m+r,=r=0k1248+r248+1+r. By taking logarithms, one can show that r=0n1nm+rnm+1+r=mm+1, for all n,m, hence r=0k1248+r248+1+r=88+1=0.888..., and the probabilities match.

We can do the same exercise with minutes instead, where m/m=60224, and Sn=n are equal to 602247, P(rains next dayrained every day last week)=r=0k1602248+r602248+1+r,0.888....