Announcement

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

  • #16
    Originally posted by kazi naher View Post
    I want to get the command to balance my unbalanced data, that is single observation for control variables to daily observation.
    Here is the final panel dataset after working on Excel and Stata. Hope this is desired outcome. Now, you can go ahead with your estimations. You declare first your data to be panel as follows:

    Code:
    xtset countries date
    Attached Files

    Comment


    • #17
      I have rearranged my data. Here is an excel copy of it. However the following errors occur.
      Attached Files

      Comment


      • #18
        i tried a normal ols regression by removing the uai variable and found my observations reduced to 4617 from 6930. I have attached screenshot of the errors and command. I want to know why are the variables ommited. And how do I fix it.
        Attached Files

        Comment


        • #19
          Originally posted by Emna Trabelsi View Post

          You need to rearrange your data in your Excel file and obtain a final dataset before running any regression. The problem is in the look of your data. I have no knowledge of a stata command that can balance your data in just one step for instance, but I will see what we can do to achieve the final result without a promise.
          I have rearranged my data and tried getting a vector of my control variables uai da if loggdp. But it says ommited due to collinearity. How do I fix it and also get a fixed effect dummy variable?
          Attached Files

          Comment


          • #20
            Originally posted by Emna Trabelsi View Post

            When you run
            Code:
            reg stockreturns democraticaccountability loggdp investment freedom uncertaintyindex i.time, robust
            , what do you obtain? Please you need to correct the names of all variables and of the time variable (I named here it time).

            You also need to give an excerpt of your data. Maybe, someone else can help.
            the following error occurs
            Attached Files

            Comment


            • #21
              Time-invariant variables are aborbed by the fixed effects. So, it is not possible to distinguish between them. I suggest to post another thread in Statalist (i.e. another post) on how to deal with time-invariant regressors in a panel model. Hope you receive more meticulous answers from someone else.
              ​​

              Comment


              • #22
                Originally posted by Emna Trabelsi View Post
                Time-invariant variables are aborbed by the fixed effects. So, it is not possible to distinguish between them. I suggest to post another thread in Statalist (i.e. another post) on how to deal with time-invariant regressors in a panel model. Hope you receive more meticulous answers from someone else.
                ​​
                I do apologize for the typo error. I meant "... are absorbed..."

                Comment


                • #23
                  Originally posted by kazi naher View Post

                  it says omitted for the control variables. I have used DATE as time
                  Dear Kazi,

                  I suggest to use 'xtseqreg' proposed by Kripfganz and Schwarz (2019). It handles time invariant regressors for both static and dynamic panels.
                  Type:
                  Code:
                  findit xtseqreg

                  Comment

                  Working...
                  X