campa.pl.plot_size_change

plot_size_change(adata, groupby_row='cluster', groupby_col='well_name', reference_row=None, reference_col=None, figsize=None, adjust_height=True, ax=None, pval=0.05, save=None, size='mean_size', limit_to_groups=None, **kwargs)[source]

Plot mean intensity differences between perturbations and clusters.

Parameters
  • adata (AnnData) – Adata containing aggregated information by clusters. E.g. result of FeatureExtractor.get_intensity_adata().

  • groupby_row (str) – Column in adata.obs containing the row-wise grouping.

  • groupby_col (str) – Column in adata.obs containing the column-wise grouping.

  • reference_row (Optional[str]) – Reference cluster/perturbation to compare to row-wise. If not defined, will compare each value in groupby_row against the rest.

  • reference_col (Optional[str]) – Reference cluster/perturbation to compare to col-wise. If not defined, will compare each value in groupby_col against the rest.

  • figsize (Optional[Tuple[int, int]]) – Size of figure.

  • adjust_height (bool) – Option to make plots a bit more streamlined.

  • ax (Optional[Axes]) – Axis to plot in.

  • pval (float) – pval threshold above which dots are not shown.

  • save (Optional[str]) – Path to save figure to.

  • size (str) – Sizes of dots, either mean_size or pval (distinguish significant and non-significant dots).

  • limit_to_groups (Optional[Mapping[str, Union[str, List[str]]]]) – Dict with obs as keys and groups from obs as values, to subset adata before plotting.

  • kwargs (Any) – Keyword arguments for sc.pl.dotplot().

Return type

None