Note: This FAQ is for users of Stata 6. It is not relevant for more recent
versions.
Stata 6: How can I remove collinear variables from a varlist?
| Title |
|
Stata 6: Removing collinear variables from a varlist |
| Author |
William Gould, StataCorp |
| Date |
December 1999 |
Assuming your Stata ado-files are up to date (type update query),
type
. help _rmcoll
_rmcoll is not
documented in the manual, but it is the routine most Stata-written ado-files
use to drop variables due to collinearity.
_rmcoll’s syntax is
_rmcoll varlist [in range] [if exp] [weight] [, noconstant]
and _rmcoll returns in r(varlist) the names of the variables
from varlist that form a noncollinear set. If any variables are
collinear, a message is also displayed for each:
Note: __________ dropped due to collinearity
(Also see the help for the related
_rmdcoll command.)
|