monkeybread.plot.cell_contact_histplot

monkeybread.plot.cell_contact_histplot(adata, groupby, contacts, expected_contacts, show=True, ax=None, **kwargs)

Plots a histogram highlighting the observed cell contact compared to permutations.

Uses the results of monkeybread.calc.cell_contact() and monkeybread.stat.cell_contact().

Creates a histogram displaying the distribution of contacts from the permutation test with a line indicating the actual distribution of contact counts.

Parameters
Return type

Optional[Axes]

Returns

If show = True, returns nothing. Otherwise, returns the Axes object the plot is contained within.