zoom.pls_tool.pls_perm

zoom.pls_tool.pls_perm(expression: pandas.DataFrame, SBP: pandas.DataFrame, SBP_perm: pandas.DataFrame, best_comp: int, scores: list, cv: int, seed: int, n_jobs: int) Tuple[float, pandas.DataFrame][source]

Perform spatial permutation test for PLS-R.

Parameters:
  • expression (pd.DataFrame) – AHBA gene expression matrix.

  • SBP (pd.DataFrame) – One-dimensional data frame of spatial brain phenotype.

  • SBP_perm (pd.DataFrame) – Spatial autocorrelation-preserved null model for SBP.

  • best_comp (int) – The optimal component number for current PLS-R model.

  • scores (list) – Model performances across repeats, as measured by Pearson’s correlation.

  • cv (int) – Number of folds.

  • seed (int) – Random seed to control the dataset split.

  • n_jobs (int) – Number of cores used for parallel computation.

Returns:

  • psa (float) – P-value accounting for spatial autocorrelation.

  • scores_perm (list) – Model performances across permutation tests, as measured by Pearson’s correlation.

References

Wang, Y. et al. Spatio-molecular profiles shape the human cerebellar hierarchy along the sensorimotor-association axis. Cell Rep. 43, 113770 (2024).