crSpanTest | R Documentation |
This function performs crTest
for a user-defined range of span
parameters, optionally allowing for multiple testing corrections in the
p-values.
crSpanTest(
model,
spfromto,
n = 10,
adjust.method = "none",
adjust.type = c("none", "across", "within", "both")
)
model |
A model object of class |
spfromto |
A vector of two values across which a range of |
n |
Number of span parameters to test. |
adjust.method |
Adjustment method for multiple-testing procedure, using
|
adjust.type |
String giving the values over which the multiple testing correction will be performed. Here, ‘both’ refers to a multiple testing correction done over all span parameters and all variables in the model. ‘within’ means the multiple testing correction should be done within each model, but not across the span parameters and ‘across’ means that the multiple testing correction should be for each variable across the various span parameters, but not across variables within the same model. ‘none’ refers to a pass-through option of no multiple testing procedure. |
A list with two elements:
x |
Sequence of span values used in testing |
y |
p-values for each variable for each span parameter |
Dave Armstrong
data(Prestige, package="carData")
mod <- lm(prestige ~ income + education + women, data=Prestige)
tmp <- crSpanTest(mod, c(.1, .9), adjust.method="holm",
adjust.type="both")
matplot(tmp$x, tmp$y, type="l")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.