Hello everyone, I am running two multiple linear regression models where the first one needs to have an interaction term between the dummy variable female (1 = female, 0=male) and a categorical variable beauty. The first model needs to have the interaction term between female and beauty, and the second one between male and beauty. I've read that i.female##c.beauty will give me the interaction term between the two variables but how should I write the regress in order to have an interaction term between female and beauty and male and beauty? I have tried the following: for the model with the interaction term between female and beauty I used regress with 1.female##c.beauty and 0.female##c.beauty for the second model but I don't know if this is the correct way to write it and if this is giving me the results I want. I also don't really understand the difference between # and ##.
Related Posts with Question on interaction terms
The problem with rcallThe package rcall is great! But when I start, I encounter a problem. When I transfor a scalar to R, …
Effect of varying number of integration points on model fit for melogitHi everyone, I am using meologit to fit a model to individual binary outcome data from a cluster ra…
How to perform an equivalence test (based on a t-test) for regression coefficients?Hi, How do I perform an equivalence test (based on a t-test) for regression coefficients in STATA? …
ttest code multiple variables that define groupHello. I cant seem to work out the coding that replicates the following function, which when copied …
OLS vs logistic regression*Hello, I was hoping someone could clarify this for me. I have used OLS regressions using the PISA d…
Subscribe to:
Post Comments (Atom)
0 Response to Question on interaction terms
Post a Comment