nispace.stats.effectsize.prc
- nispace.stats.effectsize.prc(a, b)[source]
Percent change (a - b) / a * 100, element-wise.
- Parameters:
a (array_like, shape (n_obs, n_features)) – Paired values (a is the reference/denominator); must have identical shape.
b (array_like, shape (n_obs, n_features)) – Paired values (a is the reference/denominator); must have identical shape.
- Returns:
p – NaN where a == 0 (avoids division by zero).
- Return type:
np.ndarray, shape (n_obs, n_features)
- Raises:
ValueError – If a.shape != b.shape.
Notes
NaN in a/b (other than the a == 0 guard) is not explicitly masked – it propagates through the arithmetic like any other float NaN; there is no separate prc_nan variant. Not called anywhere in NiSpace’s internal pipeline: Y_transform=”prc(a,b)” dispatches to the numba-jitted prc_fast (core/transform_y.py), not this function.