R/LRTest.R

LRTest<-function(lambda = NULL, full = NULL, reduced = NULL, df = 1){
    if(is.null(lambda)) lambda<-(-2*(full-reduced))
    lrtP <- pchisq(-lambda, df=df, lower.tail = TRUE, log.p = TRUE)
 list(lambda = lambda, Pval = lrtP)
}

Try the nadiv package in your browser

Any scripts or data that you put into this service are public.

nadiv documentation built on May 2, 2019, 4:55 p.m.