Steps followed when Binary logistic regression when both dependent and independent variables are binary

I had set of binary variables. To apply logistic regression, I have checked association between dependent and independent variables and considered only those independent variables in the model which came to be associated with dependent variable. My query is whether it is an appropriate way of fitting logistic regression model.

• yes: everyone does it. no: still subject to limitations seen in stepwise regression. this isn't equivalent to using a full pre-specified model. – charles Dec 4 '13 at 16:35
• No, this is data dredging. It yields too optimistic results, especially for smaller samples. – Michael M Dec 4 '13 at 17:31
• @charles: Well not everyone, & those that do are careful to validate the resulting model on a hold-out sample or a new data-set. – Scortchi - Reinstate Monica Dec 5 '13 at 11:20
• @Scortchi : So how should I proceed? Actually when I was taking all the variables, I was getting variables with negative coefficients which is not making business sense as independent variables are such a way that increasing independent variable will definitely increase dependent variable. That is why I have checked association between DV and IV and placed considerd only those variables which are associated with DV. – Kartikeya Pandey Dec 5 '13 at 13:41
• That's a very broad topic. I'd suggest looking at posts under the model-selection & feature-selection tags, e.g. this, this, & this - as I'm writing this I see a good answer from @charles. – Scortchi - Reinstate Monica Dec 5 '13 at 14:49