Announcement

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

  • Creating a categorical variable to include 4 dummy options

    hey guys please if anyone can help me.. quite desperate...
    so ive got data on Real GDP and housing sales in the US for a time period.. time series data
    now i need to create a regression to include seasonal fluctuations, if theres any in housing sales..
    i have 4 quarters for each year and have used each to rep a season and ive created dummy variables for each one
    then i need to create a categorical variable to include all 4 so i can just include that one in my regression to take into account the 4 seasons?

    please i really need help, not to sure if ive done this right will await a response
    thnx
    if u need anymore info on what formulas i have used i can provide them
    Last edited by Matthew.Preiss 01; 08 May 2014, 08:21.

  • #2
    Mathew,
    I believe that if you include the quarter dummies, you are already controlling for some regular seasonality on your regression. No need to include that second categorical variable you are talking about.
    HTH,
    Fernando

    Comment


    • #3
      it is not at all clear what you have done so far; please post (1) sample data and (2) your command; if you have 4 quarters, and you want to include a constant (intercept) in your model, then you can only have dummies for 3 of the seasons (otherwise you will have a redundancy in your design matrix (set of X values); you can of course, instead, use the 4 dummies without a constant in the model if that is what you want - but note that now the dummies are estimating something different from what is being estimated in the model with 3 dummies (comparisons are to zero instead of to the reference group (whichever seasonal dummy is deleted when you only include 3)

      Comment


      • #4
        Matthew: I imagine that we have sympathy with whatever situation you are in (unless it is ignoring a deadline until it is imminent!), but emphasising it does not help you get a better answer. Presumably everyone asking a question wants an answer and will appreciate attention, but being in a mess doesn't make you more deserving. The Advice Guide addresses this point

        as you have a good question, just ask it. We don't need or want detailed explanations of how much you need help, how urgent it is for you, or how grateful you will be for attention.
        I suggest that you slow down and read http://www.statalist.org/forums/help, especially sections 11 and 12. Then come back and improve your question. So far you haven't given a really clear picture of your data and you have said nothing about what commands you have used. How then can anyone say whether what you have done is correct?

        Comment


        • #5
          you do not need another variable, but first

          you could have made your dummies more easily using -tabulate- with the "gen" option - look at the help file

          now you need to show us your regression command so we can see what you are doing and how you are using the dummies

          Comment


          • #6
            leaving summer as the reference group against which each of the other 3 is then being tested (assuming, as shown, that there are no other predictors in the model)

            Comment

            Working...
            X