Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


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

Re: st: Random permutation test for rank-dependence


From   Nick Cox <[email protected]>
To   [email protected]
Subject   Re: st: Random permutation test for rank-dependence
Date   Mon, 28 Jan 2013 18:20:58 +0000

I haven't tried to understand all this, but your opening to Q2 is
incomplete. Stata has a -permute- command that transcends the specific
oldstyle testing commands you mention.

I won't be able to add more, but if you overlooked that, you probably
overlooked other things too.

Nick

On Mon, Jan 28, 2013 at 5:23 PM, Tobias Morville
<[email protected]> wrote:

> i have a question regarding random permutation testing in stata.
>
> I need to test for rank-dependence and sign-dependence, over several
> variables within each subject, and across subjects. Doing that i have
> two basic questions. But first, this is the (simplified) model I'm
> estimating:
>
>  Model: -xtprobit dummy var1 var2 var3 var1*var2 var1*var3, re-
>
> And I'm doing this for 18 different subjects, that each have ~250
> observations. They are all stacked onto each other, in one dataset.
>
> Q1: How [...] do i add parameter coefficients as new
> variables? I've googled this, and stumbled upon -estimates- module and
> -statsby-. But none of them really satisfy my needs.
>
> What i really want, is a new variable (in a column) where parameter
> estimates are continuously reported to. Lets say subject_1 has 250
> trials, then I want 250 values of b1 - which i assume is the parameter
> coefficient of var1 - to be my new variable. And so forth with all the
> other subjects, resulting in my new b1-parameter-value-variable having
> 18*~250 observations.
>
> I've done, -Estimates store- just produces b1 b2 b3 b4 b5, a "group
> level" coefficient for each of the variables (and interaction terms),
> which is not really satisfying for my need when wanting to do a random
> permutation test.
>
> Q2: For the random permutation test, stata has two non-parametric
> choices. -Ranksum- and -Median-, where the first only allows testing
> between two groups and the latter is an equility-of-median test, which
> is not really useful for me.
>
> Basically i would like to do a -ranksum- test, but between all 18
> subjects, which ranksum does not allow. Is there any alternative way
> of doing this?
>
> Background:
>
> I have a variable that is randomly distributed (it's a die) and i want
> to see if the number of eyes on that die affects how people gamble.
> When i include it as a simple regressor, it shows up significant. But
> not knowing if that (not logical - a rational agent should know its
> random) weigh on the die, is the same across subjects, and within each
> subject. Basically, i want to be able to say something about "how
> much" the die weights for different subjects, but because its
> non-linear, i can't compare a coefficient value of 2 to 4, and say its
> the double effect. Neither can i say that subject 1's coefficient of
> 5, is a lower effect of subject 2's coefficient of 7. And i need to
> find out, if i can at least, say something about the rank of the
> coefficient estimates.
>
> Hope you can help me out as I'm rather lost!
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index