# Are sampling weights necessary in logistic regression?

When should I use weights when performing a logistic regression? The weights I'm referring to are sampling weights from a survey? Or should I just use the unweighted data?

## 1 Answer

The sampling weights are designed to account for the non-simple random sample nature of your sample. Therefore, they are just as needed in one form of regression as another. Exactly how to do this may be complicated; e.g. in SAS there is PROC SURVEYLOGISTIC to deal with various sorts of samples. In R there is the survey package which I think does similar things (but I have not used it).

• Not for any form of regression. Weights in linear regression are necessary only if we think errors are not independent by $X$: (pdf). – Federico Tedeschi Dec 18 '18 at 11:11
• This paper: (pdf) adds other reasons why one should weight, that are however related to violations of the standard hypotheses: i.e.heteroskedasticity, endogenous sampling and identifying average partial effects. – Federico Tedeschi Dec 18 '18 at 11:20