|
Hi Richard,
RR> From the syntax manual entry for LOGISTIC REGRESSION, syntax template:
RR> LOGISTIC REGRESSION [VARIABLES =] dependent var
RR> [WITH independent varlist [BY var [BY var] ... ]]
RR> "· You can indicate an interaction term on the variable list by using the
RR> keyword BY to separate the individual variables."
RR> I don't quite understand this. If you use "BY var", does that mean
RR> interaction terms between "var" and all preceding variables, or what? Or
RR> can specific interaction variables be included, or excluded, on VARIABLES
RR> or METHOD subcommands?
THe syntax defines specific interaction terms. For example:
LOGISTIC REGRESSION VAR=kyphosis WITH age starvert age BY starvert
/CRITERIA = PIN(.05) POUT(.10) ITERATE(20) CUT(.5) .
This syntax models the dependent variable Kyphosis as a function of:
- Age
- Starvert
- The interaction between the two above
LOGISTIC REGRESSION VAR=kyphosis WITH age numvert starvert age BY starvert
/CRITERIA = PIN(.05) POUT(.10) ITERATE(20) CUT(.5) .
This syntax models the dependent variable Kyphosis as a function of:
- Age
- Numvert
- Starvert
- The interaction between age & starvert (numvert is not involved)
I always use "*" to indicate interaction terms, it looks clearer to me:
LOGISTIC REGRESSION VAR=kyphosis WITH age numvert starvert age*starvert
/CRITERIA = PIN(.05) POUT(.10) ITERATE(20) CUT(.5) .
--
HTH,
Marta mailto:biostatistics@terra.es
|