Nothing
#
# Ingmar Viser, 23-3-2008
#
setClass("llratio",
representation(
value="numeric",
df="numeric"
)
)
llratio <- function(basemodel,constrainedmodel,...) {
llbase <- logLik(basemodel)
llcon <- logLik(constrainedmodel)
llr <- 2*(llbase-llcon)
df <- attributes(llbase)$df-attributes(llcon)$df
return(new("llratio",value=as.numeric(llr),df=df))
}
setMethod("show","llratio",
function(object) {
pvalue=round(pchisq(object@value,object@df,lower.tail=FALSE),3)
cat("log Likelihood ratio (chi^2): ", round(object@value,3), " (df=",object@df,"), p=",pvalue,".\n",sep="")
}
)
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.