I have a problem with my panel data ( which is organised by month and municipality) were I want to take the difference between a pair of month from two different years, ex the observation for jan 2020 would be jan2020-jan2019 and the year before would imply jan2019-jan2018. This will be done for all month in my sample starting from May 2018 and going on to May 2020. I have played around with "egen" but don't really see how I can solve it. Any ideas how I could fix it?
Related Posts with Subtract over a particular pair of months
Add one overall note, text or caption to a combined coefplotHi I use coefplot to stack several graphs together. When I want to add a note, it adds to each sub g…
if loops?Hello! I'm a PhD student and relatively new to Stata. I have medicaid data, and I am assessing for …
Calculate difference across rows by the value of a third variableHi experts, My data are like below. It consists of one variable price, and another variable group. …
Replacing ICD value to another value in a datasetDear Stata Expert I would much appreicate your help on this issue. In a dataset where variabled DX1 …
Converting factor notation into dummies.Dear All, I want to conduct a two-stage least squares regression using the ivreg2 command. I have q…
Subscribe to:
Post Comments (Atom)
0 Response to Subtract over a particular pair of months
Post a Comment