NestedModels-class | R Documentation |
Implements the F-distribution used for an ANOVA or for the comparison of the fit of two
nested regression models. In both cases, the test statistic follows a F-distribution.
NestedModel
is used to compare the fit of two regression models, where one model contains
the independent variables of the smaller model as a subset. Then, one can use ANOVA to determine
whether more variance can be explained by adding more independent variables.
In the class ANOVA
, the number of independent variables of the smaller model is set to 1
in order to match the degrees of freedom and we obtain a one-way ANOVA.
NestedModels(p_inner, p_outer)
## S4 method for signature 'NestedModels'
quantile(x, probs, n, theta, ...)
## S4 method for signature 'NestedModels,numeric'
simulate(object, nsim, n, theta, seed = NULL, ...)
p_inner |
number of independent variables in smaller model |
p_outer |
number of independent variables in bigger model |
x |
outcome |
probs |
vector of probabilities |
n |
sample size |
theta |
distribution parameter |
... |
further optional arguments |
object |
object of class |
nsim |
number of simulation runs |
seed |
random seed |
p_inner
number of parameters in smaller model
p_outer
number of parameters in bigger model
See probability_density_function
and
cumulative_distribution_function
to evaluate the pdf
and the cdf, respectively. Use ANOVA
for detailed information
of ANOVA.
model <- NestedModels(2, 4)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.