Miscellanea¶
-
allel.stats.misc.
plot_variant_locator
(pos, step=None, ax=None, start=None, stop=None, flip=False, line_kwargs=None)[source]¶ Plot lines indicating the physical genome location of variants from a single chromosome/contig. By default the top x axis is in variant index space, and the bottom x axis is in genome position space.
Parameters: pos : array_like
A sorted 1-dimensional array of genomic positions from a single chromosome/contig.
step : int, optional
Plot a line for every step variants.
ax : axes, optional
The axes on which to draw. If not provided, a new figure will be created.
start : int, optional
The start position for the region to draw.
stop : int, optional
The stop position for the region to draw.
flip : bool, optional
Flip the plot upside down.
line_kwargs : dict-like
Additional keyword arguments passed through to plt.Line2D.
Returns: ax : axes
The axes on which the plot was drawn