glm function, how to select all variables except 2?

I'm trying to

  • select all columns
  • exclude 2 columns (predictor 3 and 7)
  • add one variable (predictor 1*predictor2)

The formula below doesn't work. What's the best way to do this?

glm.model <- glm(formula = target ~ . + predictor1*predictor2 - predictor 3 - predictor 7)

Take a look at this thread:

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.