brainstat.mesh.data.mesh_standardize¶
- brainstat.mesh.data.mesh_standardize(Y, mask=None, subdiv='s')[source]¶
Standardizes by subtracting the global mean, or dividing it.
- Parameters
Y (numpy array of shape (n x v)) – Data to be standardized.
mask (numpy boolean array of shape (1 x v), optional) – True is included, False is excluded. If None, no mask is applied, by default ‘None’.
subdiv (str, optional) – If ‘s’, demeans Y; if ‘d’ standardizes to mean 0, standard deviation 100.
- Returns
Y (numpy array of shape (n x v)) – Standardized data.
Ym (numpy array of shape (n x 1)) – Mean of the input Y along the mask.