Past exam of the mathematics course of the University of Cambridge 2010 ii Paper 4 13J Solution Created 2026-09-24 Updated 2026-09-24
Past exam of the mathematics course of the University of Cambridge 2011 ii Paper 4 5J Solution Created 2026-09-24 Updated 2026-09-24
Past exam of the mathematics course of the University of Cambridge 2012 iii Paper 39 4 Solution Created 2026-10-03 Updated 2026-10-07
There is a genuine qualification: the first printed inequality is valid as a useful general assertion for , but is false for arbitrary . Also the displayed likelihood ratio presupposes . We first prove the intended bound and then give a counterexample to the unrestricted quantifier.
For any estimator , set . By the triangle inequality, on , while on . HenceLet with . On , . ThereforeThe last step is Markov inequality. Taking the supremum over the model and then the infimum over estimators proves the intended metric two-point risk bound. At the right side is zero. For a negative right side is also harmless, but a positive right side need not be a lower bound.
Here is an explicit counterexample with positive probability density functions and . Let , , and take the model consisting ofUse the L2 norm metric, for which , and take for every . The majority-half decision selects if at least two observations lie in . Each error probability is , so its maximum normalized risk function is . This is also the likelihood-ratio test, giving . At the proposed right side is , contradicting the risk of this explicit estimator. Thus the intended range restriction cannot be omitted.
For the second request use the intended L2 norm metric . The PDF defines its square, not the square itself as a metric. PutBoth probability density functions belong to the model, and . The two-point choice may depend on , because the lower bound is applied separately at each sample size. Under , the product likelihood ratio satisfiesThis is the product chi-squared divergence. By Cauchy-Schwarz inequality, . With , the proved metric two-point risk bound has normalized right side greater than . ConsequentlyThe proof works for every despite the introductory . Measurability of the functions defining the probability density functions is understood. This establishes the requested lower bound; it does not assert a matching upper bound over this unrestricted class.
Past exam of the mathematics course of the University of Cambridge 2013 iii Paper 30 4 c Solution Created 2026-10-03 Updated 2026-10-07
Allow each subject to have a separate baseline and slope through a correlated random-intercept and random-slope model:The subject random effects are independent of all measurement errors, and subjects are independent. The within-person covariance between times is , with an additional when the same reading is used twice.
Prefer the model with a random slope. The maximum likelihood estimation refits improve twice the log-likelihood by while adding two covariance statistical parameters. Both the Akaike information criterion ( to ) and Bayesian information criterion ( to ) strongly favour it. The printed nominal likelihood-ratio test is overwhelming. The usual reference chi-squared distribution with two statistical degrees of freedom is not an exact regular calibration, since zero slope variance is a boundary and the intercept–slope correlation is then unidentified; a design-specific parametric bootstrap could calibrate it. This qualification does not undermine the substantial descriptive improvement shown by both information criteria.
The preferred fit estimates population mean baseline strength kg and weekly gain kg/week. The between-person baseline standard deviation is kg, and the between-person slope standard deviation is kg/week. Their estimated correlation is weakly positive, giving random-effect covariance about kg/week; its uncertainty is not supplied. The measurement-error standard deviation is kg. The printed instead describes the correlation between the estimated fixed effects, not between the subject random effects. These statistical parameter estimates come from restricted maximum likelihood; the model comparison uses the separate maximum likelihood estimation fits.
The population mean fitted trajectory is kg. HenceUsing the reported slope standard error, an approximate 95% confidence interval for the population mean gain is kg; a Student t confidence interval with 499 statistical degrees of freedom is almost identical.
Successful individuals can improve far more than the average. Their latent ten-week gains have fitted normal distributionA clear estimate for an upper-performing group uses a between-person slope quantile: the 95th percentile is kg, and the 97.5th percentile is about kg. The upper 5% of fitted underlying gains begin around 73 kg. These are person-to-person performance quantiles, not confidence intervals for the population mean. Identifying the best observed trainee would require that person's data or fitted subject random effects; the aggregate output cannot identify a literal maximum. If performance means the observed difference of endpoint readings, add the measurement-error variance to the latent gain variance.
Past exam of the mathematics course of the University of Cambridge 2013 iii Paper 30 5 b iii Solution Created 2026-10-03 Updated 2026-10-07
The cumulative-response logistic model uses instead of the two individual lag predictors. It and the two-lag history-dependent logistic regression are nonnested: the entire accumulated history generally cannot be represented using only the two recent outcomes. Their binomial deviance difference therefore has no ordinary nested chi-squared distribution calibration.
Use the Akaike information criterion, which up to the same saturated-model constant equals for these Bernoulli distribution conditional likelihoods. The two-lag fit has six coefficients, while the cumulative fit has five:Thus prefer the cumulative-history model, whose Akaike information criterion is lower by 35 despite its smaller number of statistical parameters. This is a model-selection comparison of conditional histories, not a nested likelihood-ratio test.
Past exam of the mathematics course of the University of Cambridge 2013 iii Paper 32 7 i Solution Created 2026-10-03 Updated 2026-10-07
Choose candidate variables from subject-matter knowledge, measurement quality and the target question before screening on outcomes. For an adjusted-effect analysis, retain prespecified confounders and essential design variables even when their individual values are large. For prediction, consider reliable predictors available at the intended prediction time; do not include future information. Handle missingness transparently, using a justified multiple imputation strategy where appropriate rather than changing the analyzed population unpredictably as variables enter.
Encode a categorical variable with indicators relative to a stated reference category, and assess it as a group. Check multicollinearity, sparse categories and plausible interactions. The relevant information is chiefly the number and distribution of events, not merely the number of enrolled subjects: hundreds of correlated or rarely varying predictors cannot be supported by a small event count.
Compare prespecified nested models by a likelihood-ratio test based on the partial log-likelihood and the change in parameter dimension. Penalized methods such as ridge regression or Lasso regression applied to the Cox likelihood can stabilize many-variable models; choose tuning by suitable validation and account for mandatory variables. The Akaike information criterion or a limited, documented model-selection procedure can help balance fit and complexity. Unrestricted stepwise searches and repeated univariable screening invite unstable choices, omit joint confounding effects, and make naive post-selection intervals misleading. Prefer a defensible, validated covariate set to a collection chosen only for small values.
Past exam of the mathematics course of the University of Cambridge 2014 iii Paper 33 4 a Solution 2026-10-06
The three Poisson regression models have independent counts and a logarithmic link function: their mean predictors include both
pc and urban in m1, only urban in m2, and only pc in m3. Nested comparisons through the full model are preferable to a direct comparison of the two nonnested one-predictor models.To remove
urban from m1, test against . The likelihood-ratio test statistic is the deviance differencewith approximate null distribution . It is below , so do not reject at 5%. The corresponding Wald p-value is consistent with this decision. To remove pc from m1, test against a nonzero coefficient, giving with approximate null distribution ; reject decisively. The Akaike information criterion also prefers m3, whose value is smaller than and . Past exam of the mathematics course of the University of Cambridge 2015 iii Paper 33 6 c Solution Created 2026-10-03 Updated 2026-10-06
The three-component finite Gaussian mixture with a common variance has the largest displayed maximized log-likelihood, but it also has more fitted parameters. For components there are free weights, means and one common variance, making residual-distribution parameters. Applying the nominal Akaike information criterion and Bayesian information criterion to the three residual fits givesBoth criteria favour the two-component model. It improves the likelihood substantially over one normal component; the third component gains only in log-likelihood at a cost of two further parameters. The Akaike information criterion difference between two and three components is small, about , so that criterion alone gives only a slight preference; the Bayesian information criterion preference for two is stronger. Their nearly indistinguishable overlaid curves also support retaining the simpler two-component fit.
These calculations are model-selection aids, not an exact test. Ordinary chi-squared calibration of a likelihood-ratio test for the number of mixture components is invalid in general: under a smaller-component null, some weights lie on the boundary and extra-component parameters are unidentified. This is nonregular mixture model selection. A parametric bootstrap or predictive cross-validation is preferable for a formal comparison, and should account for the mean-adjustment stage. The table uses the provided residual likelihoods and their nominal parameter counts; first-stage regression uncertainty and possible local EM maxima remain qualifications. On the supplied evidence, select two components without claiming that two distinct biological groups have been established.
Past exam of the mathematics course of the University of Cambridge 2015 ii Paper 1 10J Solution Created 2026-09-24 Updated 2026-10-06
The Poisson regression uses independent counts with mean and logarithmic link function. Writing for concentration, the fitted predictors for strains are respectivelyThe interaction formula includes concentration, strain indicators and their products. The intercept is the baseline log mean at zero toxin; exponentiating it gives about fleas. Strain coefficients compare log means at zero concentration. Interaction coefficients compare concentration slopes with the common strain. A unit concentration increase multiplies the three means by about , and respectively.
For design matrix , the fitted expected Fisher information is , , since a Poisson count has variance equal to its mean. Standard errors are square roots of diagonal entries of . Each reported Wald test divides its coefficient estimate by its standard error and compares with an approximate standard normal distribution under a zero-coefficient null, conditional on the other terms. Concentration has strong evidence of a negative baseline effect. At zero concentration strain 1 is not significant at 5% (), while strain 2 is (). The strain-1 slope differs strongly from the baseline (); the strain-2 slope has no detected difference (). A nonsignificant difference is not proof of equality. The very significant intercept is a test of mean one at zero toxin, with little scientific relevance.
Relabelling factor levels merges strains 0 and 2 into one group and leaves strain 1 separate. Model retains three intercepts but allows only two slopes: strain 1 versus the common slope of strains 0 and 2. Thus it has five parameters, compared with six in . Model merges both intercepts and slopes for strains 0 and 2, retaining only four parameters. The natural nesting is .
For these nested generalized linear models, the difference in Poisson deviance is an asymptotic likelihood-ratio test statistic with degrees of freedom equal to the parameter difference. Comparing with gives on one degree of freedom, far below : the additional strain-2 slope is unnecessary. Comparing with gives on one degree of freedom, far above : merging the strain-0 and strain-2 intercepts is rejected. Comparing with uses on two degrees of freedom and requires a two-degree-of-freedom threshold, about , rather than the supplied .
is the most appropriate of the three models: retain different strain baselines and the special strain-1 slope, but pool the unsupported strain-2 slope difference. Residual degrees of freedom are ; deviances of this magnitude give no obvious evidence of overdispersion from these summaries alone.
Past exam of the mathematics course of the University of Cambridge 2016 iii Paper 206 6 c Solution Created 2026-10-03 Updated 2026-10-06
The restricted maximum likelihood procedure estimates covariance parameters from error contrasts that remove the unknown fixed effects. Let have rank and choose an full-rank matrix with . Then has a likelihood involving the variance parameters but not . Maximizing that likelihood is restricted maximum likelihood. An equivalent restricted likelihood from orthogonal error contrasts, up to terms independent of , iswhereAfter estimating , use generalized least squares for and the conditional modes from part (b). In an independent-error normal linear model, this covariance procedure reduces to estimating by instead of .
The two models being compared have different fixed-effect spaces, so their error contrasts, dimensions, and restricted likelihoods differ. Their REML values are not likelihoods of the same transformed data and must not be used directly for this fixed-effect likelihood-ratio test. Refit both with ordinary maximum likelihood, integrating out the random effects but retaining the original response vector, and maximize each model's marginal likelihood.
The null hypothesis is , leaving the random slope variance free; the alternative permits a nonzero population stirring effect. The supplied test has , one extra fixed coefficient, and approximate p-value . Retain the fixed stirring-rate effect at 5%. A mean-zero random slope cannot substitute for an estimated nonzero population slope. The asymptotic calibration assumes regular nuisance covariance parameters and should be interpreted cautiously with only three furnaces; simulation can provide a better finite-sample calibration.
Past exam of the mathematics course of the University of Cambridge 2016 iii Paper 206 6 d Solution Created 2026-10-03 Updated 2026-10-06
The comparison removes the random slope and tests against , while retaining the same fixed intercept and slope. A variance cannot be negative, so zero is a boundary point of the parameter space. The regular Wilks theorem assumptions behind an ordinary likelihood-ratio test fail. Consequently the default chi-squared p-value from
anova is not reliably calibrated for this variance-component likelihood-ratio test at a boundary. This is different from the fixed-slope test in part (c). The reference to strength_model1 means the earlier object strength_model; no separate model 1 object was defined.A useful alternative is a parametric bootstrap. Fit the null random-intercept model, then simulate data on the actual predictor values and furnace grouping by generating null intercept effects and observation errors from its fitted Gaussian distribution. Refit null and alternative models to each simulated dataset using the same likelihood method and compute the same likelihood-ratio statistic. If is the observed statistic, estimate its upper-tail probability byThis incorporates the zero-variance boundary and the actual small group count. It is a fitted-null simulation approximation because nuisance parameters are estimated, not a universally exact test. Since both models have the same fixed-effect space, a similarly calibrated restricted-likelihood statistic is also possible. Under suitable asymptotics for a single identifiable added variance component the familiar limiting law is , but using the bootstrap avoids relying on that approximation with only three groups. There is no supplied statistic or calibrated bootstrap result here from which to decide whether the slope variance is required.
Past exam of the mathematics course of the University of Cambridge 2017 iii Paper 206 2 b Solution Created 2026-10-03 Updated 2026-10-05
There are observations, since the intercept-only model has residual degrees of freedom. Adding price introduces one coefficient and decreases the binomial deviance by . Adding a three-level factor introduces two coefficients and decreases it by . Thus the missing entries areThe likelihood-ratio test comparing the smaller and full logistic regression tests against at least one nonzero layout contrast. Its statistic is . Under ordinary interior-parameter, full-rank and finite-estimate regularity conditions, Wilks theorem gives an asymptotic chi-squared distribution with two degrees of freedom. The reported p-value exceeds , so at that level retain the simpler price-only model.
The table is an analysis of deviance for nested generalized linear models: price is entered before layout. Thus its price row tests the price-only model against an intercept, whereas the layout row tests layout after allowing for price. The latter is the relevant comparison of model1 and model2. Failing to reject a layout effect is not proof that layouts have identical effects; it means these data do not justify the extra two parameters under this test.
Past exam of the mathematics course of the University of Cambridge 2017 iii Paper 206 2 c Solution Created 2026-10-03 Updated 2026-10-05
Using the smaller logistic regression, approximate pointwise Wald confidence intervals are an estimate plus or minus times its standard error:Both intervals rely on the large-sample normal approximation and correct model assumptions. The negative slope indicates decreasing purchase probability as price rises. A one-unit price increase multiplies the odds by ; it does not subtract a fixed amount from the probability. There is no significant additional layout effect in the previous likelihood-ratio test, rather than a demonstration of no effect.
In the selected model layout B has the same prediction rule as the other layouts. At price 100 the linear predictor is . Applying the inverse logit link givesThe intercept refers to price zero; if that lies outside the observed price range, its direct substantive interpretation would require extrapolation.
Past exam of the mathematics course of the University of Cambridge 2017 iii Paper 206 4 b Solution Created 2026-10-03 Updated 2026-10-05
Let have columns , and let have one column per incubator, with entry in the column for observation 's incubator and zeros elsewhere. Integrating the Gaussian random effects givesConsequently its marginal log-likelihood isThe likelihood-ratio test of against usesFor each covariance, the optimizing coefficients are the generalized least squares estimator . Both fits should use the same marginal likelihood convention, for example fitting the alternative with
update(fly.model, REML=FALSE) and the null as a Gaussian linear model. The displayed alternative REML criterion alone cannot supply .The variance component is constrained to be nonnegative, and zero lies on the boundary. Thus the interior-parameter hypothesis of Wilks theorem fails; the usual approximation is inappropriate. A limit sometimes applies to a single variance component under additional asymptotic conditions, but four incubators do not give a persuasive large-number-of-groups approximation.
Use a parametric bootstrap under the null: estimate there; simulate independent Gaussian errors with that fitted variance at exactly the observed times and grouping labels; refit both models by maximum likelihood for each simulated sample; and calculate . The upper-tail proportion, conventionally , estimates the p-value. Boundary fits with estimated must remain in the simulation distribution. A restricted-likelihood ratio and a correspondingly calibrated bootstrap are another option when the fixed-effect design is identical, but one must not mix ordinary and restricted likelihoods in a single statistic.
Past exam of the mathematics course of the University of Cambridge 2019 ib Paper 1 19H a Solution Created 2026-09-24 Updated 2026-09-29
The Neyman-Pearson lemma says that for simple hypotheses with densities , a size- test that rejects where and accepts where , with possible randomization on equality to attain size , is most powerful among all tests of size at most . To prove it, let be this test and any competing test. Pointwise,After integration,which proves maximal power.
For the exponential sample, with ,Since , this ratio is increasing in . The likelihood-ratio test therefore rejects for large :where is the distribution function of the rate-parameterized Gamma distribution .
Past exam of the mathematics course of the University of Cambridge 2020 ii Paper 2 28J Solution Created 2026-09-24 Updated 2026-09-29
PutThe log-likelihood, apart from an additive constant, isOver the full parameter space its maximum-likelihood estimates are . Under , maximizing over the nuisance parameter gives . Thus the generalized likelihood-ratio test statistic, in the convention , is
Under , the normal-sample decomposition givesWriting , the central limit theorem for a sum of squared independent standard normal variables yields . Hence Slutsky theorem givesand in particular .
For , Taylor theorem at givesConsequentlyby the continuous mapping theorem and Slutsky's theorem. Since the square of a standard normal variable has the chi-squared distribution with one degree of freedom,
After stroke, absence of a dementia effect on the death intensity is the restrictionFit the unrestricted model and the nested model subject to this equality, then use a likelihood-ratio test. Under regularity conditions, twice the log-likelihood difference is asymptotically chi-squared with one degree of freedom.
Past exam of the mathematics course of the University of Cambridge 2021 ii Paper 1 13J a iii Solution Created 2026-09-24 Updated 2026-09-25
The additive model has four free coefficients: an intercept, two treatment contrasts, and one outcome contrast. The interaction model addstreatment-by-outcome interaction term, making six parameters for six cells. It is saturated, so the residual degrees of freedom fall from two to zero and the likelihood-ratio test has
The deviance reduction is , with p-value . The analysis of deviance for nested generalized linear models therefore gives overwhelming evidence against a common outcome distribution across the three groups. The observed proportions and the negative treatment--Worse interactions show that both doses reduce the chance of worsening relative to Control, with a larger reduction for LD.
Past exam of the mathematics course of the University of Cambridge 2023 ii Paper 4 13J ii Solution Created 2026-09-24 Updated 2026-09-25
None of the displayed one-coefficient Wald tests for
team1_form rejects at the significance level. That does not establish that formation has no effect: the relevant null hypothesis sets all nine displayed team1_form coefficients to zero simultaneously, and several individually imprecise estimates may still be jointly significant. One should compare the fitted model with the nested model omitting team1_form by an analysis of deviance for nested generalized linear models, equivalently a likelihood-ratio test of those joint restrictions. Past exam of the mathematics course of the University of Cambridge 2023 ii Paper 4 13J v Solution Created 2026-09-24 Updated 2026-09-25
The fitted Poisson regression hasso that . Hypothesis requires both restrictionsas well as the adequacy of the assumed Poisson distribution. The displayed interval addresses only the single slope restriction . Even if the separate interval for the intercept also contains zero, separate one-parameter intervals do not implement the relevant joint hypothesis test, because the two coefficient estimators can be correlated. One should test jointly, for example by a likelihood-ratio test, and separately assess the Poisson goodness of fit. Thus the slope interval alone cannot decide whether is rejected at the level.