Skip to content

caseweights when test function doesn't support it #738

Open

Description

@josef-pkt

weightstats explicitly calculates statistics with taking weights into account, the "repeat" array is never used.

I dropped levene as method, because scipy.stats.levene doesn't support weights. The cheap (in terms of code) way out is to create the full repeat array and use it for those functions.

SPSS manual describes that they are doing this (after rounding of the weights to integers).

possible problem: because of the rounding nobs of expanded array might not be the same as round(sum(weights)) if weights are not integers. Maybe add or take away one random observation.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions