Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: RE: multi-dimensional chi-squared?


From   Austin Nichols <austinnichols@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: RE: multi-dimensional chi-squared?
Date   Wed, 21 Jul 2010 12:18:22 -0400

Judy <judith.chevalier@yale.edu>:

There is almost certainly dependence over time--these products take
turns being on sale, right?  And I presume you have a more elaborate
theory to test; e.g. http://www.jstor.org/stable/2006734 or
http://scholar.google.com/scholar?cites=9915702171871712194 for some
relevant theory (i.e. is there a first mover in this sale price game?)

You might consider reformulating this as a logit or alternative binary
regression using your panel data, where each obs is a product in a
time period, and you have dummies on the RHS for one, two, or three
other products on sale (the excluded group-- zero --corresponds to the
"one product tends to be on sale at a time" hypothesis, so the joint
test on the three dummies is the one you want, I think).  Then you can
start thinking about the correlated error structure (including the
ineluctable serial correlation), mixed and random effects, etc.
Ideally, I think you would want some instruments, maybe demand
shifters, as well, depending on your theory.  Maybe that means going
to a -ivprobit- or -gmm- model, or using a triangular simultaneous
equation if there is a first mover.

On Tue, Jul 20, 2010 at 10:13 PM, Steven Samuels
<sjhsamuels@earthlink.net> wrote:
> Download -mgof-, Goodness-of-fit tests for multinomial data,  from SSC
>
> There are assumptions behind -mgof-.  One is that there is no dependence of
> the counts in different weeks (This is different from assuming that the
> decision to put an item on sale each week was independent of the decision
> for the other items that week.) . A second is that the probabilities were
> constant from week-to-week.  Without more information on how the data were
> generated, it's difficult to say more.
>
> Steve
>
> On Jul 20, 2010, at 10:54 AM, Chevalier, Judy wrote:
>
>
> Hello.  I am fairly new to this listserve.  I have a question about how one
> my think about constructing a test statistic and then  how to program it in
> STATA.  I may be missing a good way to think about it.  I will present this
> in the context of an economics/marketing dataset, though it may have a close
> analog in other domains.
>
> Consider a dataset with multiple products (let's call them 4 different
> brands of peanut butter to be concrete) observed over multiple weeks.   I
> have coded whether each product for each week is at its regular price or on
> sale.    I am interested in the question of whether one and only one product
> being on sale in a given week occurs more frequently than would be predicted
> if the product sales were independent of one another.   So, I have (easily
> calculated) the frequency with which:
>
> 0 items are on sale
> 1 item is on sale
> 2 items are on sale
> 3 items are on sale
> All 4 items are on sale.
>
> Also, given the overall frequency that each item is on sale, I have also
> easily calculated the predicted probability (under the null hypothesis of
> independence) that 0 items would be on sale, 1 item would be on sale, 2
> items would be on sale, 3 items would be on sale, etc.
>
> I can see that 1 item is on sale more frequently in the data than would be
> predicted under the null hypothesis of independence, and, of course, the
> other categories are somewhat less frequent than would be predicted under
> the null.  However, I am stymied as to how to construct an appropriate test
> statistic.    I can test for the independence of the sales for each item,
> pairwise, easily, using Stata, but I can't quite manage the right test
> statistic nor how to compute it in Stata.   I will actually repeat this test
> for some other samples--- the products will be different, the number of
> products will be different, but the hypothesis will be the same-- that 1 and
> only 1 product is on sale more often than would be predicted under the null
> of independence.
>
> If you have gotten this far-thanks for reading!
>
> Judy

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index