mmcci.pl.lrs_per_celltype

mmcci.pl.lrs_per_celltype(sample, sender=None, receiver=None, assay='raw', key='cci_scores', p_vals=None, n=15, x_label_size=18, y_label_size=24, x_tick_size=14, y_tick_size=12, figsize=(6, 5), show=True, title=None, title_size=14)[source]

Plots a bar plot of LR pairs and their proportions for a sender and receiver cell type pair along with p_values (optional).

Parameters:
  • sample (CCIData) – The CCIData object.

  • sender (str) – The sender cell type. Defaults to None.

  • receiver (str) – The receiver cell type. Defaults to None.

  • assay (str) – The assay to use. Defaults to “raw”.

  • key (str) – The key to use. Defaults to “cci_scores”.

  • p_vals (dict) – A dictionary of p-values. Defaults to None.

  • n (int) – Number of LR pairs to plot. Defaults to 15.

  • x_label_size (int) – Font size for x-axis label. Defaults to 18.

  • y_label_size (int) – Font size for y-axis label. Defaults to 24.

  • x_tick_size (int) – Font size for tick labels. Defaults to 14.

  • y_tick_size (int) – Font size for tick labels. Defaults to 12.

  • figsize (tuple) – Size of the figure. Defaults to (10, 8).

  • title (str) (optional) – Title for the plot. Defaults to None.

  • title_size (int) – Font size of the title. Defaults to 14.

Returns:

The figure

Return type:

matplotlib.figure.Figure