Pre-set variables

Functions to pre set and inspect the variables engine, id_col, theme and warnings. Note that set_engine use is compulsory to obtain the plots, the rest can be specified or not as plot parameters.

pyranges_plot.get_engine()

Returns the currently defined engine.

pyranges_plot.get_id_col()

Returns the currently defined ID column (id_col).

pyranges_plot.get_theme()

Returns the currently defined color theme.

pyranges_plot.get_warnings()

Returns the current warnings state.

pyranges_plot.set_engine(name)

Defines the engine for the plots.

Parameters:

name (str) – Indicates if Matplotlib (‘plt’, ‘matplotlib’) or Plotly (‘ply’, ‘plotly’) should be used.

Examples

>>> import pyranges_plot as prp
>>> prp.set_engine('plt')
pyranges_plot.set_id_col(name)

Defines the ID column for the data.

Parameters:

name (str) – Indicates the name of the ID column to be used when dealing with data.

Examples

>>> import pyranges_plot as prp
>>> prp.set_id_col('gene_id')
pyranges_plot.set_theme(name)

Defines the color theme for the plots.

Parameters:

name ({str, dict, None}) – Name of the predefined theme or dictionary with defined options to be set as new default. Currently available themes are “dark”, “light”, “Mariotti_lab” and “swimming_pool”.

Examples

>>> import pyranges_plot as prp
>>> prp.set_theme("dark")
>>> prp.set_theme({"title_color": "goldenrod", "exon_height": 0.8})
pyranges_plot.set_warnings(option)

Defines if the warnings should be shown.

Parameters:

option (bool) – True for showing the warnings and false to turn them off.

Examples

>>> import pyranges_plot as prp
>>> prp.set_warnings(False)