Hello,
I have a binary variable (X1) which is already in ones and zeroes on an Excel spreadsheet and I'm trying to interact this with a continuous variable (X2) but every time I do I get the error message 'factor variables may not contain noninteger values' for the binary variable. I've tried the command to declare the variable - xtreg y i.x1#c.x2, fe but that's how I keep getting the error message. There's maybe one or two missing values but other than that there's nothing out of place in the dat - I wondered if it was something to do with missing values
Does anyone have any ideas on why this is happening or what I can do?
Thanks in advance.
I have a binary variable (X1) which is already in ones and zeroes on an Excel spreadsheet and I'm trying to interact this with a continuous variable (X2) but every time I do I get the error message 'factor variables may not contain noninteger values' for the binary variable. I've tried the command to declare the variable - xtreg y i.x1#c.x2, fe but that's how I keep getting the error message. There's maybe one or two missing values but other than that there's nothing out of place in the dat - I wondered if it was something to do with missing values
Does anyone have any ideas on why this is happening or what I can do?
Thanks in advance.

Comment