An inelegant solution I arrived at (after noticing how dredge() worked with poly() terms; including or excluding the entire n x power matrix, not the individual columns) was to create a little function called "int" to create a similar matrix out of two predictors and their interaction. I called the elements produced "a", "b", and "a:b" following the convention of poly(), which calls its two elements "1" and "2".
int = function(a,b){
matOut = matrix(c(a,b,a*b),nrow=length(a))
dimnames(matOut) =list(NULL,c("a","b","a:b"))
return(matOut)}
Let's use the mtcars data set as an example, using "carb" instead of A, "gear" instead of B, and "am" instead of C to predict "mpg". Starting with the standard approach, we might try this.
require(MuMIn)
data(mtcars)
fm = lm(mpg ~ carb*gear + carb*am, mtcars,na.action=na.fail)
length(dredge(fm))
This produces 11 possible models with all combinations of the three linear terms and the two interaction terms.
Now, if we use int() instead of *, we see we only get four models; each interaction, their combination, and the null model. All models are excluded that contain linear terms without the interaction.
fm = lm(mpg ~ int(carb,gear) + int(carb,am), mtcars,na.action=na.fail)
length(dredge(fm))