Hello Members,

I have a pressing doubt in implementing the diff in diff in Stata 17. - didregress command.

My research question explores the impact of mobile phone usage on the crop yield of farmers. In this model, I have a continuous outcome (crop yield of farmers), treatment variable (usage of phones), few covariates (farm level variables), Time variable (crop season A and crop season B) and group variable - ??

The didregress requires the following command for cross sectional - repeated measures data -
"didregress (y1 x1 x2) (treat1), group(grpvar1) time(tvar)"

In the current case, I have crop yield data (outcome variable) of 1000 farmers in two crop seasons (time-variable), whereas the treatment is the usage of phones (measured in number of minutes over the study period). Given the above command, my research question, and the data available, I have two doubts -

1. What is the group variable for the didregress model in this case? As you see, I am not giving intervention based on any groups. I thought each farmer was his/her own group. But I got errors while executing this
2. How do I implement continuous treatment variable in didregress? I know that we need to specify "(treatment_variable, continuous)" but that doesn't seem to work and throws errors.

Can someone please help me in this?
Regards