c2v.pl.shap_volcano

Contents

c2v.pl.shap_volcano#

c2v.pl.shap_volcano(shapdata, layer, min_corr=0.5, xlabel='corr(SHAP, Expr)', ylabel='mean(|SHAP|)', title=None, return_fig=False, show=True, figsize=None, ax=None, **kwargs)#

Draws volcano-like plot showing the result of the associations analysis with CatBoost and SHAP.

Parameters:
shapdata AnnData

Annotated data matrix with SHAP values in layers[layer] and gene expression correlations in varm[“gex_r”][layer].

layer str

Layer in shapdata.layers with SHAP values.

min_corr float, optional

Minimum correlation threshold for plotting. Default is 0.5.

xlabel str, optional

Label for the x-axis. Default is “corr(SHAP, Expr)”.

ylabel str, optional

Label for the y-axis. Default is “mean(|SHAP|)”.

title str | None, optional

Title for the plot. Default is None.

return_fig bool, optional

Whether to return the figure object. Default is False.

show bool, optional

Whether to show the plot. Default is True.

figsize tuple[float, float] | None, optional

Figure size. Default is None.

ax matplotlib.axes.Axes | None, optional

Axes object to draw on. Default is None.

**kwargs

Additional keyword arguments for volcano().

Return type:

plt.Figure | matplotlib.axes.Axes | None