mvpa2.measures.rsa.rankdata

mvpa2.measures.rsa.rankdata(a)

Ranks the data, dealing with ties appropriately.

Equal values are assigned a rank that is the average of the ranks that would have been otherwise assigned to all of the values within that set. Ranks begin at 1, not 0.

Parameters :

a : array_like

This array is first flattened.

Returns :

rankdata : ndarray

An array of length equal to the size of a, containing rank scores.

Examples

>>> stats.rankdata([0, 2, 2, 3])
array([ 1. ,  2.5,  2.5,  4. ])

Previous topic

mvpa2.measures.rsa.pearsonr

Next topic

mvpa2.measures.rsa.squareform

NeuroDebian

NITRC-listed