For events with , the conditional probability is . Applying the definition in both orders gives Bayes theorem:
Conditionally on , independent fair tosses give a binomial distribution for the head count, so . The joint probability mass function is consequently
Use the law of total probability and the differentiated geometric series, , to obtain . The posterior coin count after exactly one head is therefore
These probabilities sum to one by the same series identity. The conditioning weights possible coin counts by their likelihood of producing exactly one head.
Let mean that the selected coin is biased and that it is fair. Both have prior probability . Conditional on either coin, tosses are independent. For the observed head count, the two binomial distribution likelihoods are and . Bayes theorem cancels the common coefficient and equal prior weights, giving
This applies for , including endpoint coin biases with zero-power factors interpreted by the corresponding likelihood. The fair-coin likelihood is positive, so the denominator cannot vanish.
For a finite stopping time with target , necessarily . The last toss must be a head and the preceding tosses must contain heads. The negative binomial stopping argument therefore gives likelihood for the biased coin, and for the fair coin. Applying Bayes theorem again yields
The two experiments have different combinatorial coefficients, but each coefficient is independent of the coin parameter. Thus posterior equality for proportional likelihoods explains their identical posterior formula. If , a finite positive-head stopping observation has zero likelihood under the biased coin, consistently giving posterior zero. If the target is , the experiment stops at without a toss and the posterior remains ; a positive stopping time would then be impossible.
By the partition and the law of total probability, . Also . Combining these identities proves Bayes theorem:
The assumed positive probabilities make the conditional expressions well defined.
Multiplying the likelihood function by the Pareto distribution prior gives
The integral of this kernel is , so the normalized posterior distribution is
Thus it is . This proves uniform-Pareto conjugacy: applying Bayes theorem preserves the family of prior distributions.
Model gives the sequential forecast . The probability chain rule yields
Application of Bayes theorem makes the factors successive posterior predictive distributions, and their product is the Bayesian model evidence. Under conditionally independent sampling it is
Taking logarithms gives the prequential log score identity
Therefore the Bayes factor is
This solves the second half of part (d), which is missing from the TeX. Proper priors and finite positive evidences are needed; unrelated improper-prior normalizing constants do not cancel.
Let be one fixed model indicator with equal prior probabilities, and put . Within each model the parameters are already updated using the same past data. The Bayesian model averaging forecast is . Upon observing , Bayes theorem gives
Taking the ratio cancels the denominator and gives the prescribed update because . Iteration yields
The weights are posterior model probabilities and their mixture is the full Bayesian predictive density. The indicator is fixed across days, rather than choosing a fresh model independently each morning.
Let mean membership in the structural-zero component. Under the fitted zero-inflated Poisson regression, , whereas . By Bayes theorem, the posterior structural-zero probability is
Using the printed predictions for this patient gives
The fitted conditional probability is about . It is larger than the prior fitted structural-zero probability , because observing no episodes increases the probability of latent membership in that component. The interpretation “never at risk” is the model's structural class; an observed six-month zero alone does not identify the class with certainty.
Interpret random choice of coin as equal prior probabilities, and the tosses as independent conditional on the chosen coin. Let denote two heads. The conditional probabilities are and . For posterior coin selection from repeated tosses, Bayes theorem gives
The tosses need not be unconditionally independent, because the same hidden coin is used twice. If the coin-choice prior were instead , the answer would be ; equal choice gives the stated .
For nondecreasing uniform samples in the lottery, all ordered samples have equal probability by the discrete uniform distribution and independence. A nondecreasing sample is uniquely specified by its multiplicities , with . The stars and bars argument places separators among identical markers, giving multiplicity vectors. There is exactly one nondecreasing ordered sample for each such vector, so the probability is
This counts samples with ties correctly; multiplying a single strictly increasing count by would not handle the repeated values.
A complete-case analysis changes the mix of people contributing to the logistic regression. Let mean that both required variables are observed, and write . Within , Bayes theorem gives
If completeness depends differently on the two responses, and that selection also varies with partner count or the other predictors, the extra term changes the fitted regression coefficients. For example, people with high counts and poor condom use can be under-represented, weakening or otherwise distorting the apparent association. Dropping people with missing also excludes some whose membership of the target group is unknown.
The fitted conditional association among complete responders need not equal the target-population association. No direction of selection bias follows without specifying the response mechanism. Selection on predictors alone need not bias a correctly specified conditional logistic regression; it is the outcome-related selection described here that removes that reassurance.
Use the Bayes theorem to multiply the Ising model prior by the conditionally independent normal likelihood factors. For fixed observed , the posterior distribution is
There is no boundary wraparound: the neighbor sets use only actual horizontal and vertical edges inside the square. Each unordered edge is counted once. In particular, the prior retains the printed minus sign in front of , and the likelihood retains the seventh power. The finite state space and finite observed values make every posterior weight positive and finite, with a finite positive normalizing sum.
For EM for zero-inflated negative binomial regression, at iteration apply Bayes theorem to each zero in the zero-inflated negative binomial model. The E step computes the conditional expectation of its latent indicator:
Treating these values as fixed, the M step maximizes the expected complete-data log-likelihood. Its two parameter blocks separate:
The second block is a weighted negative binomial regression with fixed size . Writing and , its parameter-dependent objective is
Its score function and negative Hessian matrix are
The objective is concave, so a finite maximizer, when it exists, can be found by Newton method or iteratively reweighted least squares. The latter uses working response and weights . This is not an unweighted regression on only the positive counts: zeros retain fractional weight in the count component.
Start with and finite coefficients, alternate the two steps, and monitor the observed log-likelihood. Exact maximization makes the expectation-maximization algorithm nondecreasing in that likelihood, although the mixture may have multiple stationary points. All-zero data can lead to boundary fits and poor identification; multiple initializations and explicit checks for boundary parameters are useful.
Let contain independent complete observations of the -dimensional vector, and let be a Directed acyclic graph. A Gaussian Bayesian network uses, for node ,
Here is an intercept, the vector of parent coefficients, and the conditional variance; the vector collects these statistical parameters. Its likelihood function factors as
Choose a proper statistical parameter prior distribution and a graph prior distribution . Bayes theorem gives the Bayesian network structure score, up to the normalization common to graphs,
The integral is Bayesian model evidence: it averages over nuisance parameters rather than substituting their best-fitting values. A graph prior can favor sparse graphs, while the evidence balances fit against the amount of prior statistical parameter space that predicts the observations well. Compare these scores over admissible Directed acyclic graphs, using enumeration when feasible or a search procedure otherwise; search need not find a global maximum, and observational data need not identify a unique causal orientation.
A conjugate prior makes the integral analytic. For example, for take , , where is positive-definite matrix and ; these are independent local normal-inverse-gamma priors. Under prior independence between nodes, the evidence is a product of local regression evidences. Each posterior has the same family, so the local integral is the ratio of prior and posterior normalization constants, with the likelihood's constants included. This avoids costly numerical integration and makes local graph updates inexpensive. Hyperparameters must be specified coherently if score equivalence between observationally equivalent graphs is desired; arbitrary local priors do not automatically have that property.
Use Bayes theorem with the individual survivor function. Writing , the frailty distribution among survivors has density
Hence
The conditional expectation starts at one and declines toward zero when . Survival favors the less frail individuals, precisely explaining why the population hazard under exponential frailty equals times a decreasing multiplier. The original PDF asks for conditioning on the event ; the TeX's misplaced inequality is a transcription error, not conditioning on an observed exact event time.
Let . Bayes theorem and the stated prior factorization give the posterior density
The normalizing constant, when finite and positive, is the integral of this product over its admissible parameter domain. An improper prior requires checking posterior propriety before interpreting this expression as a probability density.
At a given time write and , the conditional probability that the next search succeeds if box is chosen. Compare two consecutive searches , keeping the continuation after two failures fixed. Their expected costs up to that common continuation are
The probability of reaching the common continuation is the same in either order. Moreover,
Repeated adjacent interchanges move a box with maximal index to the front without increasing expected cost; applying the same argument after every failure proves the optimal index for Bayesian box search policy
For completeness, after an unsuccessful search of box , Bayes theorem gives the posterior in the Bayesian box search problem: