Tweedie is credited for a formula first published in Robbins (1956), which offers "a simple empirical Bayes approach to correcting selection bias". Let μ μ be a latent variable we don't observe, but we know it has a certain prior distribution p ( μ μ ) . Let x = μ μ + ϵ ϵ be an observable, where ϵ ϵ ∼ ∼ N ( 0 , Σ Σ ) is a Gaussian noise variable (so p ( x | μ μ ) = N ( x | μ μ , Σ Σ ) ). Let ρ ρ ( x ) = ∫ ∫ p ( x | μ μ ) p ( μ μ ) d μ μ be the probability density of x , then the posterior mean and variance of μ μ given the observed x are: E [ μ μ | x ] = x + Σ Σ ∇ ∇ ρ ρ ( x ) ρ ρ ( x ) ; V a r [ μ μ | x ] = E [ μ μ μ μ T | x ] − − E [ μ μ | x ] E [ μ μ | x ] T = Σ Σ ( ∇ ∇ 2 ρ ρ ( x ) ρ ρ ( x ) − − ∇ ∇ ρ ρ ( x ) ∇ ∇ ρ ρ ( x ) T ρ ρ ( x ) 2 ) Σ Σ + Σ Σ The posterior higher order moments of μ μ are also obtainable as algebraic expressions of ∇ ∇ ρ ρ , ρ ρ , Σ Σ .