I have the following variables and if they were in wide format I would calculate something like
lm(happiness ~ personality_trait*condition)
But my data is in long format. I suppose it will be a repeated measures model but I'm not sure. I considered Linear Mixed Models but I'm not sure if I understood and whether it is what I'm looking for.
Thanks a lot!
| participant | personality_trait1 | condition | happiness |
|---|---|---|---|
| 1 | 10 | animal | 5 |
| 1 | 10 | human | 7 |
| 2 | 2 | animal | 3 |
| 2 | 2 | human | 4 |
| 3 | 5 | animal | 6 |
| 3 | 5 | human | 2 |