Announcement

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

  • Panel data with three dependent variables

    Hi all,

    I am pretty basic with statistics, but already have some experience with Stata.

    In my current research, I have a panel data from 1990-2010 and want to test, whether the coffee price has an impact on two different variables of several coffee producing companies: acquisition rate and employees (based on my literature research). How would you translate this into a correct statistical test, as we usually have the value of the dependent variable, depending on the values of several independent variables, with this research it would be different?

    Thank you already in advance!
    John

  • #2
    John:
    welcome to this forum.
    Your three dependent variable are, in fact, 2 (acquisition rate and employees).
    That said, I've never heard about such a study design: the tempative answer is to consider -mvreg- with -i.year- among predictors and -bootstrap- standard errors to account for the non-Independence of the observations belonging to the same panel.
    Just one caveat: are you sure that price, in turn, does not explain acquisition rate? If that were the case, I would be concerned about the risk of endogeneity (reverse causality) that may affect your regression model(s).

    Kind regards,
    Carlo
    (Stata 19.0)

    Comment


    • #3
      Hi Carlo,
      thank you already for your helpful answer, you are right with only having 2 dependent variables!
      Regarding your question, isnt that what I measure when I take price as the independent variable, which should explain acquisition rate and employees as my dependent variables? At least that is what I want to find out.
      Kind regards,
      Alexander

      Comment


      • #4
        Welcome to the Stata Forum / Statalist,

        Please read the FAQ. There you'll find the advice to use real name as well as family name.

        You may re-register by clicking on the "contact us" button in the lower right corner. Thanks.

        P.S.: Edited to highlight my fondness (as well as Carlo's, as we read below!) of the above-mentioned philosopher.
        Last edited by Marcos Almeida; 18 Feb 2019, 03:52.
        Best regards,

        Marcos

        Comment


        • #5
          Alexander (despite your nickname reminds me of an English philosopher I was very fond of when I was at the high school -sadly, it was about 40 years ago- please note our strong preference on this forum for real names - see the FAQ on this. Thanks).
          If, based on the literature of your research field you're not concerned about the risk of reversal causality, that's fine.
          What I figured out is that an increasing price can well explain a reduction in the acquisition rate, just like an increasing acquisition rate can explain upward variation in price: obviously, I can be far out of target here.

          PS: Marcos too was fond of John Locke!
          Kind regards,
          Carlo
          (Stata 19.0)

          Comment


          • #6
            @both, thank you for the remark, I requested the change of name already.

            @Carlo, thank you for the advice. I will dig deeper into that possibility, although I only found literature on the one side (price explaining acquisition). Is there a possibility to test this via Stata?

            Best regards,
            Johannes

            Comment


            • #7
              Johannes (or Alexander, ruling out John Locke?):
              if the relationship between price and acquistion is proved to proceed in one direction only, things are easier.
              You can suspect endogeneity if your model is misspecified (although misspecification can be due to different reasons).
              You can test for misspecification with the Pregibon's test (Pregibon D. Goodness of link tests for generalized linear models. Applied Statistics 1980;29: 15–24), as you can see in the following toy-example:
              Code:
              . use "http://www.stata-press.com/data/r15/nlswork.dta"
              (National Longitudinal Survey.  Young Women 14-26 years of age in 1968)
              
              . xtreg ln_wage race
              
              Random-effects GLS regression                   Number of obs     =     28,534
              Group variable: idcode                          Number of groups  =      4,711
              
              R-sq:                                           Obs per group:
                   within  = 0.0000                                         min =          1
                   between = 0.0121                                         avg =        6.1
                   overall = 0.0133                                         max =         15
              
                                                              Wald chi2(1)      =      63.13
              corr(u_i, X)   = 0 (assumed)                    Prob > chi2       =     0.0000
              
              ------------------------------------------------------------------------------
                   ln_wage |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
              -------------+----------------------------------------------------------------
                      race |  -.0994584   .0125177    -7.95   0.000    -.1239928   -.0749241
                     _cons |   1.786115   .0174161   102.56   0.000      1.75198     1.82025
              -------------+----------------------------------------------------------------
                   sigma_u |  .38371707
                   sigma_e |  .32028665
                       rho |  .58937401   (fraction of variance due to u_i)
              ------------------------------------------------------------------------------
              
              . predict fitted, xb
              
              . g sq_fitted=fitted^2
              
              . xtreg ln_wage fitted sq_fitted
              
              Random-effects GLS regression                   Number of obs     =     28,534
              Group variable: idcode                          Number of groups  =      4,711
              
              R-sq:                                           Obs per group:
                   within  = 0.0000                                         min =          1
                   between = 0.0198                                         avg =        6.1
                   overall = 0.0186                                         max =         15
              
                                                              Wald chi2(2)      =      99.02
              corr(u_i, X)   = 0 (assumed)                    Prob > chi2       =     0.0000
              
              ------------------------------------------------------------------------------
                   ln_wage |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
              -------------+----------------------------------------------------------------
                    fitted |  -58.46806   10.00039    -5.85   0.000    -78.06847   -38.86766
                 sq_fitted |   18.25845   3.070162     5.95   0.000     12.24105    24.27586
                     _cons |   48.36546   8.135371     5.95   0.000     32.42043    64.31049
              -------------+----------------------------------------------------------------
                   sigma_u |  .38195681
                   sigma_e |  .32028665
                       rho |  .58714668   (fraction of variance due to u_i)
              ------------------------------------------------------------------------------
              
              . test sq_fitted
              
               ( 1)  sq_fitted = 0
              
                         chi2(  1) =   35.37
                       Prob > chi2 =    0.0000
              
              * The statistical significance of -test- on fitted^2 means misspecification.


              Kind regards,
              Carlo
              (Stata 19.0)

              Comment


              • #8
                Thank you a lot for your support!

                Comment

                Working...
                X