Usage
# fit <- fitting.function(formula=response ~ terms, x=TRUE, y=TRUE)
validate(fit, method="boot", B=40,
bw=FALSE, rule="aic", type="residual", sls=0.05, aics=0,
force=NULL, estimates=TRUE, pr=FALSE, ...)
## S3 method for class 'validate':
print(x, digits=4, B=Inf, \dots)
## S3 method for class 'validate':
latex(object, digits=4, B=Inf, file='', append=FALSE,
title=first.word(deparse(substitute(x))),
caption=NULL, table.env=FALSE,
size='normalsize', extracolsize=size, ...)
Arguments
fit
a fit derived by e.g. lrm
, cph
, psm
, ols
. The options x=TRUE
and y=TRUE
must have been specified.
method
may be "crossvalidation"
, "boot"
(the default), ".632"
, or
"randomization"
.
See predab.resample
for details. Can abbreviate, e.g.
"cross", "b", ".6"
.
B
number of repetitions. For method="crossvalidation"
, is the
number of groups of omitted observations. For print.validate
and latex.validate
, B
is an upper limit on the number
of resamples for whi
bw
TRUE
to do fast step-down using the fastbw
function,
for both the overall model and for each repetition. fastbw
keeps parameters together that represent the same factor.
rule
Applies if bw=TRUE
. "aic"
to use Akaike's information criterion as a
stopping rule (i.e., a factor is deleted if the $\chi^2$ falls below
twice its degrees of freedom), or "p"
to use $P$-values.
type
"residual"
or "individual"
- stopping rule is for individual factors or
for the residual $\chi^2$ for all variables deleted
sls
significance level for a factor to be kept in a model, or for judging the
residual $\chi^2$.
aics
cutoff on AIC when rule="aic"
.
pr
TRUE
to print results of each repetition
...
parameters for each specific validate function, and parameters to
pass to predab.resample
(note especially the group
,
cluster
, amd subset
parameters). For latex
,
optional arguments
x,object
an object produced by one of the validate
functions
digits
number of decimal places to print
file
file to write LaTeX output. Default is standard output.
append
set to TRUE
to append LaTeX output to an existing
file
title, caption, table.env, extracolsize
see
latex.default
. If table.env
is
FALSE
and caption
is given, the character string
contained in caption
will be placed before the table size
size of LaTeX output. Default is 'normalsize'
. Must
be a defined LaTeX size when prepended by double slash.