# 似然比检验 LRT

30 篇文章 10 订阅

$H_0:\theta =\theta _0$

$H_1:$ 对$\theta$没有约束

$\lambda (X)=\frac{L_0^*}{L_1^*}$      或者写成对数形式  $-2log\lambda =2(l_1^*-l_2^*)$

[ 注：通常写成乘以2形式是为了之后推导中近似变换为卡方值，即$-2log\lambda$ 的渐进分布是 $\chi _{q-r}^2$ ，其中 $\Omega _0\in \Omega _1$ 是 $r$ 维 ]

1. 基于平行的定义，这些轮廓相似吗（轮廓是否平行，注意这里不相交便意味着平行）？
2. 如果轮廓是平行的，二者处于同一水平吗（两组轮廓是否为同一轮廓）？
3. 如果轮廓是平行的，但二者不处于同一水平，轮廓存在治疗效应吗（无论接受何种治疗，轮廓是否始终保持相同，趋势是否一致）？

In statistics, a likelihood ratio test (LR test) is a statistical test used for comparing the goodness of fit of two statistical models — a null model against an alternative model. The test is based on the likelihood ratio, which expresses how many times more likely the data are under one model than the other. This likelihood ratio, or equivalently its logarithm, can then be used to compute a p-value, or compared to a critical value to decide whether or not to reject the null model.

When the logarithm of the likelihood ratio is used, the statistic is known as a log-likelihood ratio statistic, and the probability distribution of this test statistic, assuming that the null model is true, can be approximated using Wilks' theorem.

In the case of distinguishing between two models, each of which has no unknown parameters, use of the likelihood ratio test can be justified by the Neyman–Pearson lemma, which demonstrates that such a test has the highest power among all competitors.

Being a function of the data x, the likelihood ratio is therefore a statistic. The likelihood ratio test rejects the null hypothesis if the value of this statistic is too small. How small is too small depends on the significance level of the test, i.e., on what probability of Type I error is considered tolerable ("Type I" errors consist of the rejection of a null hypothesis that is true).

The numerator corresponds to the likelihood of an observed outcome under the null hypothesis. The denominator corresponds to the maximum likelihood of an observed outcome varying parameters over the whole parameter space. The numerator of this ratio is less than the denominator. The likelihood ratio hence is between 0 and 1. Low values of the likelihood ratio mean that the observed result was less likely to occur under the null hypothesis as compared to the alternative. High values of the statistic mean that the observed outcome was nearly as likely to occur under the null hypothesis as the alternative, and the null hypothesis cannot be rejected.

The likelihood-ratio test requires nested models – models in which the more complex one can be transformed into the simpler model by imposing a set of constraints on the parameters. If the models are not nested, then a generalization of the likelihood-ratio test can usually be used instead: the relative likelihood.

library(rms)
all.X <-data.frame(x.T=data.T, x.N=data.N, x.S=data.S, x.G=data.G, x.V=data.V, x.P=data.P, x.CEA2=data.CEA2, x.CA1992=data.CA1992)
TN.model <- cph(Surv(survival.time,survival.status)~ x.T+x.N,
data=all.X, na.action=na.omit )
TNC.model <- cph(Surv(survival.time,survival.status)~ x.T+x.N+x.CEA2,
data=all.X, na.action=na.omit )
TN2TNC <- lrtest(TN.model, TNC.model)

《应用多元统计分析》 Wolfgang Hardle等著，陈诗一译. 北京大学出版社

• 10
点赞
• 0
评论
• 87
收藏
• 一键三连
• 扫一扫，分享海报

09-05 7195
03-19 480

03-09 8918
11-26 9193
03-30 517
12-16 1232
11-21 4877
08-19
11-13
07-27 4873
08-08 6960
09-19 7191
08-14 2万+
06-28