Announcement

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

  • Company Fixed effects

    Hi everyone,

    I would like to calculate the acquirer fixed effects, but something is wrong with my stata Command.

    My dataset contains of multiple acquirers which have done multiple deals over multiple years.


    For every acquirer i have the cusip, permno and the cumulative abnormal return (car5).



    The car5 should be the dependent variable my regression and the acquirer fixed effect should be the independent variable.




    Im using the following Command:
    xtset cusip year
    streng car5 cusip, fe


    This is what i get: repeated time values within panel, r(451)





    But this does not work.


    Could someone help me out?


    Click image for larger version

Name:	Foto 21-02-2020 om 22.42.jpeg
Views:	1
Size:	139.1 KB
ID:	1537825

  • #2
    We see that 00077R has two observations for 1996, and 000886 has five observations for 1996.

    This is what is meant by "repeated time values within panel".

    It might be helpful to you to review the Introduction to xt commands section of the Stata Longitudinal-Data/Panel-Data Reference Manual PDF included in your Stata installation and accessible through Stata's Help menu.

    Comment


    • #3
      Noud:
      it is not clear how -cusip- can be at the same time -panelid- and predictor.
      Hence, I do share William's advice to review -xt- entries in Stata .pdf manual.
      That said, the error message thrown by Stata can be ignored by -xtset-ting your data with -panelid- only. Please note that this workaround works It you do not plan to use time-series related commands, such as lags and leads.
      Kind regards,
      Carlo
      (Stata 19.0)

      Comment


      • #4
        Hi William and Carlo,

        I have read the manual you both refered to, but it is still not clear to me how to solve this problem.

        All the time stata gives me an error message: repeated time values within panel..

        I have made a time_id in order to create panel data, but it does not give me the opportunitie to make the xtreg regression.

        What am i doing wrong?


        Comment


        • #5
          In post #4 Carlos tells you that panel data does not require a time identifier, it only requires a panel identifer. The output of help xtset tells us
          Code:
                                              xtset panelvar declares the data in memory to be a
              panel in which the order of observations is irrelevant.  xtset panelvar timevar
              declares the data to be a panel in which the order of observations is relevant.  When
              you specify timevar, you can then use Stata's time-series operators and analyze your
              data with the ts commands without having to tsset your data.

          Comment

          Working...
          X