Stata: Data Analysis and Statistical Software
   >> Home >> Resources & support >> FAQs >> Stata 6: Removing collinear variables from a varlist
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.)

Bookmark and Share 
FAQs
What's new?
Statistics
Data management
Graphics
Programming Stata
Mata
Resources
Internet capabilities
Stata for Windows
Stata for Unix
Stata for Mac
Technical support
Like us on Facebook Follow us on Twitter Follow us on LinkedIn Google+ Watch us on YouTube
Follow us
© Copyright 1996–2013 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index   |   View mobile site