fastbw deletes factors, not columns of the design matrix. Factors requiring multiple d.f. will be retained or dropped as a group.
The function prints the deletion statistics for each variable in
turn, and prints approximate parameter estimates for the model after
deleting variables. The approximation is better when the number of
factors deleted is not large. For ols, the approximation is exact for
regression coefficients, and standard errors are only off by a factor
equal to the ratio of the mean squared error estimate for the reduced
model to the original mean squared error estimate for the full model.If the fit was from ols, fastbw will compute the usual $R^2$
statistic for each model.
fastbw(fit, rule="aic", type="residual", sls=.05, aics=0, eps=1e-9, k.aic=2)## S3 method for class 'fastbw':
print(x, digits=4, \dots)
Varcov(fit) defined (e.g., from ols, lrm, cph, psm, glmD)"aic" for Akaike's information criterion. Use
rule="p" to use $P$-values"residual" for
the pooled residual chi-square. Use type="individual" to use Wald
chi-square of individual factors.rule="p". Default is .05.rule="aic",
variables are deleted until the chi-square - k.aic times d.f. falls below aics.
Default aics is zero to use the ordinary AIC. Set aics to say 10000
to see all variables dele1E-9.k.aic equal
to $\log(n)$, where $n$ is the effective sample size (number of events
for survival models).fastbwfactors.kept.parms.kept.rms, ols, lrm,
cph, psm, validate,
solvet, rmsMiscfastbw(fit, optional.arguments) # print results
z <- fastbw(fit, optional.args) # typically used in simulations
lm.fit(X[,z$parms.kept], Y) # least squares fit of reduced modelRun the code above in your browser using DataLab