發表文章

目前顯示的是 4月, 2018的文章

Buffon's needle and Buffon's noodle

圖片
The  probability distribution  of the number of crossings depends on the shape of the noodle, but the  expected number  of crossings does not; it depends only on the length  L   of the noodle and the distance  D   between the parallel lines (observe that a curved noodle may cross a single line multiple times). This fact may be proved as follows (see Klain and Rota). First suppose the noodle is  piecewise linear , i.e. consists of  n straight pieces. Let  X i  be the number of times the  i th piece crosses one of the parallel lines. These random variables are not  independent , but the expectations are still additive due to the  linearity of expectation : {\displaystyle E(X_{1}+\cdots +X_{n})=E(X_{1})+\cdots +E(X_{n}).}   ( wiki )

data science matrix from udacity

圖片

Bayesian

圖片
Bayesian view: 对于任一个未知量 theta, 都可以看作是有其概率分布的随机变量,它的概率分布是抽样前就有的关于 theta 的先验信息的概率陈述(Prior)。 Bayesian view: Two steps to generate the sample x, First,  we need to sample  f(theta) to get a theta'. Secondly,  from p(x|theta') to get sample x = (x1, x2, ... xn). p(x|theta') = continuely-multiplication p(xi|theta)  (联合概率密度函数) 这个联合密度函数综合了总体信息和样本信息,称为似然函数 L(theta')

Hidden Markov Model 0

圖片

Notes on "Theories on Deep Learning" (Stats 385)

圖片

Markov Chain

Random walk!

Monte Carlo (Simulation)

圖片
Generate data via simulation ! A method of estimating the value of an unknown quantity using the principles of inferential statistics. Inferential statistics: a random sample tends to exhibit the same properties as the population from which it was drawn. Example : 1, Marriage problem or  Secretary problem , which is the mathematical version of the game of googol : Ask someone to take as many slips of paper as he pleases, and on each slip write a different positive number. The numbers may range from small fractions of 1 to a number the size of a googol (1 followed by a hundred 0s) or even larger. These slips are turned face down and shuffled over the top of a table. One at a time you turn the slips face up. The aim is to stop turning when you come to the number that you guess to be the largest of the series. You cannot go back and pick a previously turned slip. If you turn over all the slips, then of course you must pick the last one turned. a) solution : that is the 1/e...

Metropolis-Hastings

圖片
Metropolis–Hastings and other MCMC algorithms are generally used for sampling from multi-dimensional distributions, especially when the number of dimensions is high. For single-dimensional distributions, other methods are usually available (e.g.  adaptive rejection sampling ) that can directly return independent samples from the distribution, and are free from the problem of  autocorrelated  samples that is inherent in MCMC methods.   The Metropolis–Hastings algorithm can draw samples from any  probability distribution   P ( x ), provided you can compute the value of a function  f ( x ) that is  proportional  to the density of  P . The last requirement that  f ( x ) should be merely proportional to the density, rather than exactly equal to it, makes the Metropolis–Hastings algorithm particularly useful, because calculating the necessary normalization factor is often extremely difficult  in practice . (from Wiki ) Th...