- spac.transformations.apply_per_batch(data, annotation, method, **kwargs)[source]
Apply a given function to data per batch, with additional parameters.
- Parameters:
data (np.ndarray) – The data to transform.
annotation (np.ndarray) – Batch annotations for each row in the data.
method (str) – The function to apply to each batch. Options: ‘arcsinh_transformation’ or ‘normalize_features’.
kwargs – Additional parameters to pass to the function.
- Returns:
The transformed data.
- Return type:
np.ndarray