metachat.pp.global_intensity_scaling
- metachat.pp.global_intensity_scaling(adata_ref, adata_target, method='tic', scales=1e-05)[source]
Perform global intensity scaling of adata_target to match adata_ref, using either total ion current (TIC) or root-mean-square (RMS) normalization.
Parameters
- adata_ref
Reference dataset for scaling (e.g., negative ion mode).
- adata_target
Target dataset to be scaled (e.g., positive ion mode).
- method
Scaling method to use: - ‘tic’: scale by total ion current (sum of all intensities) - ‘rms’: scale by root-mean-square of intensities
- scales
Optional global scaling factor applied to both datasets (default: 1e-5).
Returns
- adata_refanndata.AnnData
Scaled reference dataset.
- adata_targetanndata.AnnData
Scaled target dataset.