Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • getting transformed variables in reghdfe

    Hello everyone,

    I have a problem with reghdfe and reg2hdfe I hope someone here can help me with. I have a code with reg2hdfe which I want to know what is the equivalent of it is in reghdfe. the program is supposed to pre-run a regression with fixed effects and doing so, demeans the data and gives the transformed data in "tdir" so it can be used in other parts of code. specifically, the line is:

    Code:
    reg2hdfe Y X, id1(panelvar) id2(timevar) out(tdir) noregress
    if I want to write the equivalent in reghdfe, what should I do? In particular, I know that I can write something like this:

    Code:
    reghdfe Y X, absorb(panelvar timevar)
    but is there a way to save the transformed variables somewhere? like what the "out(tdir)" part does in reg2hdfe?

    (the reason I want to do that is that I want to introduce weights. reghdfe supports weights but reg2hdfe doesn't)
    Last edited by Ramin Forouzandeh; 11 Mar 2020, 08:01.
Working...
X