scipy / stats : quantiles using sample weights from survey data

Aahz aahz at pythoncraft.com
Wed Aug 18 21:32:59 CEST 2010


In article <94bb6313-1b09-4eeb-9969-07d76048a361 at m35g2000prn.googlegroups.com>,
Christopher Barrington-Leigh  <christopherbl at gmail.com> wrote:
>
>There is a function scipy.stats.mstats.mquantiles  that returns
>quantiles for a vector of data.
>But my data should not be uniformly weighted in an estimate of the
>distribution, since they are from a survey and come with estimated
>sampling weights based on the stratification used in sampling.
>
>Is there a routine to calculate these quantiles taking into account
>the survey weights?  I can find nothing, so maybe you have had the
>same problem and written something.

You should ask on the scipy mailing list.
-- 
Aahz (aahz at pythoncraft.com)           <*>         http://www.pythoncraft.com/

"...if I were on life-support, I'd rather have it run by a Gameboy than a
Windows box."  --Cliff Wells



More information about the Python-list mailing list