Bookmark and Share

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

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

Re: st: bootstrap with mixed logit

From (Brendan Halpin)
Subject   Re: st: bootstrap with mixed logit
Date   Fri, 27 Jan 2012 21:22:07 +0000

On Fri, Jan 27 2012, Stas Kolenikov wrote:

> I would not expect this work, as the class labels will always be
> different in different bootstrap samples: what is class 1 in the
> original sample may be class 3 in the first bootstrap subsample, and
> class 4 in the second one, etc. With a single run, a permutation of
> class labels is irrelevant, but matching the classes over repeated
> runs, as is needed for the bootstrap, is extremely cumbersome.

It's likely not to be relevant for this application, but I have
encountered this problem before (correlating more than one unlabelled
same-sized classifications of the same data). Mata's permutation
capabilities can be used to identify the permutation of one class which
best matches the other. A good quantity to maximise is Cohen's kappa,
though clearly many others are possible.

I have an implementation (permtab.ado) as part of my SADI package (-net
from ; -net install sadi- ), which
can generate a new variable from the best permutation. For five classes
the number of permutations is very small so it would be quick. For eight
classes it's bearable (but perhaps not in a bootstrap context) but much
above 8 it's very slow. I have a home-brewed genetic algorithm version
(permtabga.ado) which searches for an approximate solution for larger
numbers of cases (Mata made it surprisingly easy to code a GA).


PS: the ado-files are stand-alone so they can be downloaded as etc. (.hlp files too).
Brendan Halpin,   Department of Sociology,   University of Limerick,   Ireland
Tel: w +353-61-213147  f +353-61-202569  h +353-61-338562;  Room F1-009 x 3147    ULSociology on Facebook:         twitter:@ULSociology
*   For searches and help try:

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