I want to model the effect of Level (continuous) of different Additives (categorical) on Y (continuous) by fitting a linear model, so my data is going to look like this:

Additive   Level   Y
A            1     2.3
A            2     4.5
A            3     6.7
B            1     8.9
B            2     1.0

I could fit that with something like Y ~ Level %in% Additive

But what about zero level? At zero level additive identity doesn't mean anything. I don't want to include another variable indicating whether any additive is present because that would split off the zero level data. I want the zero level data to be used in estimating the regressions for all the Additives, but I don't know how to enter the data, never mind how to specify the model!

It feels as if this must be a recognised situation with "standard" approaches. I've hit it before but never resolved it to my own satisfaction, now it's arisen again. Can anyone point me in the right direction?

  • $\begingroup$ Answering my own question, at least to an extent. I think I was seeing a problem where there wasn't one, perhaps because Minitab gave me an "insufficient rank" error when fitting a nested model to data containing several 'Additive = None, Level = 0' rows. R gave me an answer with Y ~ Level %in% Additive. Perhaps the way to think of it is to lose the categorical 'Additive' column and have a different continuous 'Level' column for each Additive; no additive is just zero in all the Level columns. I think Minitab may be able to fit such a model by multiple linear regression; I'll try on Monday. $\endgroup$
    – user20637
    Mar 23, 2013 at 9:57
  • $\begingroup$ My previous comment was correct. R fits just the model I need with Y ~ Level %in% Additive. In Minitab I can get the same fit but I need a separate Level column for each 'Additive'. Sorry for the waste of bandwidth. $\endgroup$
    – user20637
    Mar 25, 2013 at 12:53


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.