Hello,
I am trying to understand how binscatter plots work and I have a somewhat general question in case of panel data. For example, let the variables be a, b, and c, for the period from 1990-2020. I would like to do a binscatter of the variable a against the average value of variable b by municipality for each decade, controlling for variable c, something like this:
by municipality decade, sort: gen b_m=mean(b)
binsreg a b_m c, nbins(15) if decade==1990
Given that I want on x axis to have the average value of variable b by municipality, does it make sense to run a simple binsreg like this "binsreg a b_m c, nbins(15) if decade==1990" or do I also need to compute the average values of both of b and c variables before doing binsreg?
Thank you very much for your help.
Related Posts with Binsreg question
Clustering Industry typesI have constructed the following one year lagged regression of ESG on ROA. However, I do not get an …
Reduce number of decimals in twostepweakiv outputHello, I was trying to use the twostepweakiv command to compute the AR 95% confidence intervals. The…
Using IVREG2HPlease can someone help me with the use of the ivreg2h command for analysis? My dependent variable i…
Generating average variable of previous observationsHi All, I am writing my Bachelor thesis which is about how total payout policy (dividends + share r…
Dark themeI have STATA 17 on Linux. I use a Linux dark theme for my desktop. Stata generally respect the the…
Subscribe to:
Post Comments (Atom)
0 Response to Binsreg question
Post a Comment