Hi,

I am creating a long-run average of crime rates disaggregated which are reported at the district-month level for the years 2000-2010. I sum the number of crimes per month for all months for each municipality and divide by the number of months in the time interval using the following code where count is the monthly number:

Code:
bysort districtid : egen countsum = total(count)
gen lr_av=countsum/132
I use this variable in a regression which includes
Code:
reghdfe dv count lr_av count*lr_av, cluster(districtid) a(districtid state##yearmonth)
The lr_av variable (the level coefficient) drops out due to collinearity given the districted FE- but is the this the correct way to construct the LR average to interpret the interaction term?

Thanks.