From b9540a6df2c4f8197e3f67a3bdf2c64c7a6b07f6 Mon Sep 17 00:00:00 2001 From: <> Date: Sat, 11 Jan 2025 16:25:46 +0000 Subject: [PATCH] Deployed 4b434c6 with MkDocs version: 1.6.1 --- .nojekyll | 0 404.html | 618 ++ api-docs/circos/index.html | 4529 +++++++++++ api-docs/sector/index.html | 2631 +++++++ api-docs/track/index.html | 5322 +++++++++++++ api-docs/treeviz/index.html | 2367 ++++++ api-docs/utils/index.html | 1967 +++++ assets/_mkdocstrings.css | 143 + assets/images/favicon.png | Bin 0 -> 1870 bytes assets/javascripts/bundle.88dd0f4e.min.js | 16 + assets/javascripts/bundle.88dd0f4e.min.js.map | 7 + assets/javascripts/lunr/min/lunr.ar.min.js | 1 + assets/javascripts/lunr/min/lunr.da.min.js | 18 + assets/javascripts/lunr/min/lunr.de.min.js | 18 + assets/javascripts/lunr/min/lunr.du.min.js | 18 + assets/javascripts/lunr/min/lunr.el.min.js | 1 + assets/javascripts/lunr/min/lunr.es.min.js | 18 + assets/javascripts/lunr/min/lunr.fi.min.js | 18 + assets/javascripts/lunr/min/lunr.fr.min.js | 18 + assets/javascripts/lunr/min/lunr.he.min.js | 1 + assets/javascripts/lunr/min/lunr.hi.min.js | 1 + assets/javascripts/lunr/min/lunr.hu.min.js | 18 + assets/javascripts/lunr/min/lunr.hy.min.js | 1 + assets/javascripts/lunr/min/lunr.it.min.js | 18 + assets/javascripts/lunr/min/lunr.ja.min.js | 1 + assets/javascripts/lunr/min/lunr.jp.min.js | 1 + assets/javascripts/lunr/min/lunr.kn.min.js | 1 + assets/javascripts/lunr/min/lunr.ko.min.js | 1 + assets/javascripts/lunr/min/lunr.multi.min.js | 1 + assets/javascripts/lunr/min/lunr.nl.min.js | 18 + assets/javascripts/lunr/min/lunr.no.min.js | 18 + assets/javascripts/lunr/min/lunr.pt.min.js | 18 + assets/javascripts/lunr/min/lunr.ro.min.js | 18 + assets/javascripts/lunr/min/lunr.ru.min.js | 18 + assets/javascripts/lunr/min/lunr.sa.min.js | 1 + .../lunr/min/lunr.stemmer.support.min.js | 1 + assets/javascripts/lunr/min/lunr.sv.min.js | 18 + assets/javascripts/lunr/min/lunr.ta.min.js | 1 + assets/javascripts/lunr/min/lunr.te.min.js | 1 + assets/javascripts/lunr/min/lunr.th.min.js | 1 + assets/javascripts/lunr/min/lunr.tr.min.js | 18 + assets/javascripts/lunr/min/lunr.vi.min.js | 1 + assets/javascripts/lunr/min/lunr.zh.min.js | 1 + assets/javascripts/lunr/tinyseg.js | 206 + assets/javascripts/lunr/wordcut.js | 6708 +++++++++++++++++ .../workers/search.6ce7567c.min.js | 42 + .../workers/search.6ce7567c.min.js.map | 7 + assets/stylesheets/main.6f8fc17f.min.css | 1 + assets/stylesheets/main.6f8fc17f.min.css.map | 1 + assets/stylesheets/palette.06af60db.min.css | 1 + .../stylesheets/palette.06af60db.min.css.map | 1 + chord_diagram/index.html | 1976 +++++ circos_plot/index.html | 2680 +++++++ comparative_genomics/index.html | 1696 +++++ getting_started/index.html | 2157 ++++++ images/example01.png | Bin 0 -> 214411 bytes images/example02.png | Bin 0 -> 119806 bytes images/example03.png | Bin 0 -> 208163 bytes images/example04.png | Bin 0 -> 379045 bytes images/example05.png | Bin 0 -> 119502 bytes images/pyCirclize_gallery.png | Bin 0 -> 1252636 bytes index.html | 779 ++ objects.inv | Bin 0 -> 1071 bytes phylogenetic_tree/index.html | 3216 ++++++++ plot_api_example/index.html | 4392 +++++++++++ plot_tips/index.html | 2541 +++++++ radar_chart/index.html | 1741 +++++ search/search_index.json | 1 + sitemap.xml | 3 + sitemap.xml.gz | Bin 0 -> 127 bytes 70 files changed, 46036 insertions(+) create mode 100644 .nojekyll create mode 100644 404.html create mode 100644 api-docs/circos/index.html create mode 100644 api-docs/sector/index.html create mode 100644 api-docs/track/index.html create mode 100644 api-docs/treeviz/index.html create mode 100644 api-docs/utils/index.html create mode 100644 assets/_mkdocstrings.css create mode 100644 assets/images/favicon.png create mode 100644 assets/javascripts/bundle.88dd0f4e.min.js create mode 100644 assets/javascripts/bundle.88dd0f4e.min.js.map create mode 100644 assets/javascripts/lunr/min/lunr.ar.min.js create mode 100644 assets/javascripts/lunr/min/lunr.da.min.js create mode 100644 assets/javascripts/lunr/min/lunr.de.min.js create mode 100644 assets/javascripts/lunr/min/lunr.du.min.js create mode 100644 assets/javascripts/lunr/min/lunr.el.min.js create mode 100644 assets/javascripts/lunr/min/lunr.es.min.js create mode 100644 assets/javascripts/lunr/min/lunr.fi.min.js create mode 100644 assets/javascripts/lunr/min/lunr.fr.min.js create mode 100644 assets/javascripts/lunr/min/lunr.he.min.js create mode 100644 assets/javascripts/lunr/min/lunr.hi.min.js create mode 100644 assets/javascripts/lunr/min/lunr.hu.min.js create mode 100644 assets/javascripts/lunr/min/lunr.hy.min.js create mode 100644 assets/javascripts/lunr/min/lunr.it.min.js create mode 100644 assets/javascripts/lunr/min/lunr.ja.min.js create mode 100644 assets/javascripts/lunr/min/lunr.jp.min.js create mode 100644 assets/javascripts/lunr/min/lunr.kn.min.js create mode 100644 assets/javascripts/lunr/min/lunr.ko.min.js create mode 100644 assets/javascripts/lunr/min/lunr.multi.min.js create mode 100644 assets/javascripts/lunr/min/lunr.nl.min.js create mode 100644 assets/javascripts/lunr/min/lunr.no.min.js create mode 100644 assets/javascripts/lunr/min/lunr.pt.min.js create mode 100644 assets/javascripts/lunr/min/lunr.ro.min.js create mode 100644 assets/javascripts/lunr/min/lunr.ru.min.js create mode 100644 assets/javascripts/lunr/min/lunr.sa.min.js create mode 100644 assets/javascripts/lunr/min/lunr.stemmer.support.min.js create mode 100644 assets/javascripts/lunr/min/lunr.sv.min.js create mode 100644 assets/javascripts/lunr/min/lunr.ta.min.js create mode 100644 assets/javascripts/lunr/min/lunr.te.min.js create mode 100644 assets/javascripts/lunr/min/lunr.th.min.js create mode 100644 assets/javascripts/lunr/min/lunr.tr.min.js create mode 100644 assets/javascripts/lunr/min/lunr.vi.min.js create mode 100644 assets/javascripts/lunr/min/lunr.zh.min.js create mode 100644 assets/javascripts/lunr/tinyseg.js create mode 100644 assets/javascripts/lunr/wordcut.js create mode 100644 assets/javascripts/workers/search.6ce7567c.min.js create mode 100644 assets/javascripts/workers/search.6ce7567c.min.js.map create mode 100644 assets/stylesheets/main.6f8fc17f.min.css create mode 100644 assets/stylesheets/main.6f8fc17f.min.css.map create mode 100644 assets/stylesheets/palette.06af60db.min.css create mode 100644 assets/stylesheets/palette.06af60db.min.css.map create mode 100644 chord_diagram/index.html create mode 100644 circos_plot/index.html create mode 100644 comparative_genomics/index.html create mode 100644 getting_started/index.html create mode 100644 images/example01.png create mode 100644 images/example02.png create mode 100644 images/example03.png create mode 100644 images/example04.png create mode 100644 images/example05.png create mode 100644 images/pyCirclize_gallery.png create mode 100644 index.html create mode 100644 objects.inv create mode 100644 phylogenetic_tree/index.html create mode 100644 plot_api_example/index.html create mode 100644 plot_tips/index.html create mode 100644 radar_chart/index.html create mode 100644 search/search_index.json create mode 100644 sitemap.xml create mode 100644 sitemap.xml.gz diff --git a/.nojekyll b/.nojekyll new file mode 100644 index 0000000..e69de29 diff --git a/404.html b/404.html new file mode 100644 index 0000000..80dc7ef --- /dev/null +++ b/404.html @@ -0,0 +1,618 @@ + + + +
+ + + + + + + + + + + + + + + + + + +Circos(
+ sectors: Mapping[str, int | float | tuple[float, float]],
+ start: float = 0,
+ end: float = 360,
+ *,
+ space: float | list[float] = 0,
+ endspace: bool = True,
+ sector2clockwise: dict[str, bool] | None = None,
+ show_axis_for_debug: bool = False
+)
+
Circos Visualization Class
+ + + +PARAMETER | +DESCRIPTION | +
---|---|
+ sectors
+ |
+
+
+
+ Sector name & size (or range) dict +
+
+ TYPE:
+ |
+
+ start
+ |
+
+
+
+ Plot start degree (
+
+ TYPE:
+ |
+
+ end
+ |
+
+
+
+ Plot end degree (
+
+ TYPE:
+ |
+
+ space
+ |
+
+
+
+ Space degree(s) between sector +
+
+ TYPE:
+ |
+
+ endspace
+ |
+
+
+
+ If True, insert space after the end sector +
+
+ TYPE:
+ |
+
+ sector2clockwise
+ |
+
+
+
+ Sector name & clockwise bool dict. By default,
+
+ TYPE:
+ |
+
+ show_axis_for_debug
+ |
+
+
+
+ Show axis for position check debugging (Developer option) +
+
+ TYPE:
+ |
+
property
+
+
+Circos radian limit
+property
+
+
+Circos degree limit
+property
+
+
+Plot polar axes
+Can't access ax
property before calling circos.plotfig()
method
staticmethod
+
+
+radar_chart(
+ table: str | Path | pd.DataFrame | RadarTable,
+ *,
+ r_lim: tuple[float, float] = (0, 100),
+ vmin: float = 0,
+ vmax: float = 100,
+ fill: bool = True,
+ marker_size: int = 0,
+ bg_color: str | None = "#eeeeee80",
+ circular: bool = False,
+ cmap: str | dict[str, str] = "Set2",
+ show_grid_label: bool = True,
+ grid_interval_ratio: float | None = 0.2,
+ grid_line_kws: dict[str, Any] | None = None,
+ grid_label_kws: dict[str, Any] | None = None,
+ grid_label_formatter: Callable[[float], str] | None = None,
+ label_kws_handler: Callable[[str], dict[str, Any]] | None = None,
+ line_kws_handler: Callable[[str], dict[str, Any]] | None = None,
+ marker_kws_handler: Callable[[str], dict[str, Any]] | None = None
+) -> Circos
+
Plot radar chart
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ table
+ |
+
+
+
+ Table file or Table dataframe or RadarTable instance +
+
+ TYPE:
+ |
+
+ r_lim
+ |
+
+
+
+ Radar chart radius limit region (0 - 100) +
+
+ TYPE:
+ |
+
+ vmin
+ |
+
+
+
+ Min value +
+
+ TYPE:
+ |
+
+ vmax
+ |
+
+
+
+ Max value +
+
+ TYPE:
+ |
+
+ fill
+ |
+
+
+
+ If True, fill color of radar chart. +
+
+ TYPE:
+ |
+
+ marker_size
+ |
+
+
+
+ Marker size +
+
+ TYPE:
+ |
+
+ bg_color
+ |
+
+
+
+ Background color +
+
+ TYPE:
+ |
+
+ circular
+ |
+
+
+
+ If True, plot with circular style. +
+
+ TYPE:
+ |
+
+ cmap
+ |
+
+
+
+ Colormap assigned to each target row(index) in table.
+User can set matplotlib's colormap (e.g.
+
+ TYPE:
+ |
+
+ show_grid_label
+ |
+
+
+
+ If True, show grid label. +
+
+ TYPE:
+ |
+
+ grid_interval_ratio
+ |
+
+
+
+ Grid interval ratio (0.0 - 1.0) +
+
+ TYPE:
+ |
+
+ grid_line_kws
+ |
+
+
+
+ Keyword arguments passed to
+
+ TYPE:
+ |
+
+ grid_label_kws
+ |
+
+
+
+ Keyword arguments passed to
+
+ TYPE:
+ |
+
+ grid_label_formatter
+ |
+
+
+
+ User-defined function to format grid label (e.g.
+
+ TYPE:
+ |
+
+ label_kws_handler
+ |
+
+
+
+ Handler function for keyword arguments passed to
+
+ TYPE:
+ |
+
+ line_kws_handler
+ |
+
+
+
+ Handler function for keyword arguments passed to
+
+ TYPE:
+ |
+
+ marker_kws_handler
+ |
+
+
+
+ Handler function for keyword arguments passed to
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ circos
+ |
+
+
+
+ Circos instance initialized for radar chart +
+
+ TYPE:
+ |
+
staticmethod
+
+
+chord_diagram(
+ matrix: str | Path | pd.DataFrame | Matrix,
+ *,
+ start: float = 0,
+ end: float = 360,
+ space: float | list[float] = 0,
+ endspace: bool = True,
+ r_lim: tuple[float, float] = (97, 100),
+ cmap: str | dict[str, str] = "viridis",
+ link_cmap: list[tuple[str, str, str]] | None = None,
+ ticks_interval: int | None = None,
+ order: str | list[str] | None = None,
+ label_kws: dict[str, Any] | None = None,
+ ticks_kws: dict[str, Any] | None = None,
+ link_kws: dict[str, Any] | None = None,
+ link_kws_handler: Callable[[str, str], dict[str, Any] | None] | None = None
+) -> Circos
+
Plot chord diagram
+Circos tracks and links are auto-defined from Matrix
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ matrix
+ |
+
+
+
+ Matrix file or Matrix dataframe or Matrix instance +
+
+ TYPE:
+ |
+
+ start
+ |
+
+
+
+ Plot start degree (-360 <= start < end <= 360) +
+
+ TYPE:
+ |
+
+ end
+ |
+
+
+
+ Plot end degree (-360 <= start < end <= 360) +
+
+ TYPE:
+ |
+
+ space
+ |
+
+
+
+ Space degree(s) between sector +
+
+ TYPE:
+ |
+
+ endspace
+ |
+
+
+
+ If True, insert space after the end sector +
+
+ TYPE:
+ |
+
+ r_lim
+ |
+
+
+
+ Outer track radius limit region (0 - 100) +
+
+ TYPE:
+ |
+
+ cmap
+ |
+
+
+
+ Colormap assigned to each outer track and link.
+User can set matplotlib's colormap (e.g.
+
+ TYPE:
+ |
+
+ link_cmap
+ |
+
+
+
+ Link colormap to overwrite link colors automatically set by cmap.
+User can set list of
+
+ TYPE:
+ |
+
+ ticks_interval
+ |
+
+
+
+ Ticks interval. If None, ticks are not plotted. +
+
+ TYPE:
+ |
+
+ order
+ |
+
+
+
+ Sort order of matrix for plotting Chord Diagram. If
+
+ TYPE:
+ |
+
+ label_kws
+ |
+
+
+
+ Keyword arguments passed to
+
+ TYPE:
+ |
+
+ ticks_kws
+ |
+
+
+
+ Keyword arguments passed to
+
+ TYPE:
+ |
+
+ link_kws
+ |
+
+
+
+ Keyword arguments passed to
+
+ TYPE:
+ |
+
+ link_kws_handler
+ |
+
+
+
+ User-defined function to handle keyword arguments for each link.
+This option allows user to set or override properties such as
+
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ circos
+ |
+
+
+
+ Circos instance initialized from Matrix +
+
+ TYPE:
+ |
+
staticmethod
+
+
+initialize_from_tree(
+ tree_data: str | Path | Tree,
+ *,
+ start: float = 0,
+ end: float = 360,
+ r_lim: tuple[float, float] = (50, 100),
+ format: str = "newick",
+ outer: bool = True,
+ align_leaf_label: bool = True,
+ ignore_branch_length: bool = False,
+ leaf_label_size: float = 12,
+ leaf_label_rmargin: float = 2.0,
+ reverse: bool = False,
+ ladderize: bool = False,
+ line_kws: dict[str, Any] | None = None,
+ label_formatter: Callable[[str], str] | None = None,
+ align_line_kws: dict[str, Any] | None = None
+) -> tuple[Circos, TreeViz]
+
Initialize Circos instance from phylogenetic tree
+Circos sector and track are auto-defined by phylogenetic tree
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ tree_data
+ |
+
+
+
+ Tree data (
+
+ TYPE:
+ |
+
+ start
+ |
+
+
+
+ Plot start degree (-360 <= start < end <= 360) +
+
+ TYPE:
+ |
+
+ end
+ |
+
+
+
+ Plot end degree (-360 <= start < end <= 360) +
+
+ TYPE:
+ |
+
+ r_lim
+ |
+
+
+
+ Tree track radius limit region (0 - 100) +
+
+ TYPE:
+ |
+
+ format
+ |
+
+
+
+ Tree format (
+
+ TYPE:
+ |
+
+ outer
+ |
+
+
+
+ If True, plot tree on outer side. If False, plot tree on inner side. +
+
+ TYPE:
+ |
+
+ align_leaf_label
+ |
+
+
+
+ If True, align leaf label. +
+
+ TYPE:
+ |
+
+ ignore_branch_length
+ |
+
+
+
+ If True, ignore branch length for plotting tree. +
+
+ TYPE:
+ |
+
+ leaf_label_size
+ |
+
+
+
+ Leaf label size +
+
+ TYPE:
+ |
+
+ leaf_label_rmargin
+ |
+
+
+
+ Leaf label radius margin +
+
+ TYPE:
+ |
+
+ reverse
+ |
+
+
+
+ If True, reverse tree +
+
+ TYPE:
+ |
+
+ ladderize
+ |
+
+
+
+ If True, ladderize tree +
+
+ TYPE:
+ |
+
+ line_kws
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
+ align_line_kws
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
+ label_formatter
+ |
+
+
+
+ User-defined label text format function to change plot label text content.
+For example, if you want to change underscore of the label to space,
+set
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ circos
+ |
+
+
+
+ Circos instance +
+
+ TYPE:
+ |
+
+ tv
+ |
+
+
+
+ TreeViz instance +
+
+ TYPE:
+ |
+
staticmethod
+
+
+initialize_from_bed(
+ bed_file: str | Path,
+ start: float = 0,
+ end: float = 360,
+ *,
+ space: float | list[float] = 0,
+ endspace: bool = True,
+ sector2clockwise: dict[str, bool] | None = None
+) -> Circos
+
Initialize Circos instance from BED file
+Circos sectors are auto-defined by BED chromosomes
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ bed_file
+ |
+
+
+
+ Chromosome BED format file (zero-based coordinate) +
+
+ TYPE:
+ |
+
+ start
+ |
+
+
+
+ Plot start degree (-360 <= start < end <= 360) +
+
+ TYPE:
+ |
+
+ end
+ |
+
+
+
+ Plot end degree (-360 <= start < end <= 360) +
+
+ TYPE:
+ |
+
+ space
+ |
+
+
+
+ Space degree(s) between sector +
+
+ TYPE:
+ |
+
+ endspace
+ |
+
+
+
+ If True, insert space after the end sector +
+
+ TYPE:
+ |
+
+ sector2clockwise
+ |
+
+
+
+ Sector name & clockwise bool dict. By default,
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ circos
+ |
+
+
+
+ Circos instance initialized from BED file +
+
+ TYPE:
+ |
+
add_cytoband_tracks(
+ r_lim: tuple[float, float],
+ cytoband_file: str | Path,
+ *,
+ track_name: str = "cytoband",
+ cytoband_cmap: dict[str, str] | None = None
+) -> None
+
Add track & plot chromosome cytoband on each sector
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ r_lim
+ |
+
+
+
+ Radius limit region (0 - 100) +
+
+ TYPE:
+ |
+
+ cytoband_file
+ |
+
+
+
+ Cytoband tsv file (UCSC format) +
+
+ TYPE:
+ |
+
+ track_name
+ |
+
+
+
+ Cytoband track name. By default,
+
+ TYPE:
+ |
+
+ cytoband_cmap
+ |
+
+
+
+ User-defined cytoband colormap. If None, use Circos style colormap.
+(e.g.
+
+ TYPE:
+ |
+
Get sector by name
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ name
+ |
+
+
+
+ Sector name +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ sector
+ |
+
+
+
+ Sector +
+
+ TYPE:
+ |
+
Get degree min-max limit in target group sectors
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ group_sector_names
+ |
+
+
+
+ Group sector names +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ group_sectors_deg_lim
+ |
+
+
+
+ Degree limit in group sectors +
+
+ TYPE:
+ |
+
Plot axis
+By default, simple black axis params(fc="none", ec="black", lw=0.5
) are set.
PARAMETER | +DESCRIPTION | +
---|---|
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
text(
+ text: str,
+ *,
+ r: float = 0,
+ deg: float = 0,
+ adjust_rotation: bool = False,
+ orientation: str = "horizontal",
+ **kwargs
+) -> None
+
Plot text
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ text
+ |
+
+
+
+ Text content +
+
+ TYPE:
+ |
+
+ r
+ |
+
+
+
+ Radius position +
+
+ TYPE:
+ |
+
+ deg
+ |
+
+
+
+ Degree position (0 - 360) +
+
+ TYPE:
+ |
+
+ adjust_rotation
+ |
+
+
+
+ If True, text rotation is auto set based on
+
+ TYPE:
+ |
+
+ orientation
+ |
+
+
+
+ Text orientation (
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
line(
+ *,
+ r: float | tuple[float, float],
+ deg_lim: tuple[float, float] | None = None,
+ arc: bool = True,
+ **kwargs
+) -> None
+
Plot line
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ r
+ |
+
+
+
+ Line radius position (0 - 100). If r is float, (r, r) is set. +
+
+ TYPE:
+ |
+
+ deg_lim
+ |
+
+
+
+ Degree limit region (-360 - 360). If None,
+
+ TYPE:
+ |
+
+ arc
+ |
+
+
+
+ If True, plot arc style line for polar projection. +If False, simply plot linear style line. +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
rect(
+ r_lim: tuple[float, float] = (0, 100),
+ deg_lim: tuple[float, float] | None = None,
+ **kwargs
+) -> None
+
Plot rectangle
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ r_lim
+ |
+
+
+
+ Radius limit region (0 - 100) +
+
+ TYPE:
+ |
+
+ deg_lim
+ |
+
+
+
+ Degree limit region (-360 - 360). If None,
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
link(
+ sector_region1: tuple[str, float, float],
+ sector_region2: tuple[str, float, float],
+ r1: float | None = None,
+ r2: float | None = None,
+ *,
+ color: str = "grey",
+ alpha: float = 0.5,
+ height_ratio: float = 0.5,
+ direction: int = 0,
+ arrow_length_ratio: float = 0.05,
+ allow_twist: bool = True,
+ **kwargs
+) -> None
+
Plot link to specified region within or between sectors
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ sector_region1
+ |
+
+
+
+ Link sector region1 (name, start, end) +
+
+ TYPE:
+ |
+
+ sector_region2
+ |
+
+
+
+ Link sector region2 (name, start, end) +
+
+ TYPE:
+ |
+
+ r1
+ |
+
+
+
+ Link radius end position for sector_region1. +If None, lowest radius position of track in target sector is set. +
+
+ TYPE:
+ |
+
+ r2
+ |
+
+
+
+ Link radius end position for sector_region2. +If None, lowest radius position of track in target sector is set. +
+
+ TYPE:
+ |
+
+ color
+ |
+
+
+
+ Link color +
+
+ TYPE:
+ |
+
+ alpha
+ |
+
+
+
+ Link color alpha (transparency) value +
+
+ TYPE:
+ |
+
+ height_ratio
+ |
+
+
+
+ Bezier curve height ratio +
+
+ TYPE:
+ |
+
+ direction
+ |
+
+
+
+
+
+ TYPE:
+ |
+
+ arrow_length_ratio
+ |
+
+
+
+ Direction arrow length ratio +
+
+ TYPE:
+ |
+
+ allow_twist
+ |
+
+
+
+ If False, twisted link is automatically resolved. +http://circos.ca/documentation/tutorials/links/twists/images +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
link_line(
+ sector_pos1: tuple[str, float],
+ sector_pos2: tuple[str, float],
+ r1: float | None = None,
+ r2: float | None = None,
+ *,
+ color: str = "black",
+ height_ratio: float = 0.5,
+ direction: int = 0,
+ arrow_height: float = 3.0,
+ arrow_width: float = 2.0,
+ **kwargs
+) -> None
+
Plot link line to specified position within or between sectors
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ sector_pos1
+ |
+
+
+
+ Link line sector position1 (name, position) +
+
+ TYPE:
+ |
+
+ sector_pos2
+ |
+
+
+
+ Link line sector position2 (name, position) +
+
+ TYPE:
+ |
+
+ r1
+ |
+
+
+
+ Link line radius end position for sector_pos1. +If None, lowest radius position of track in target sector is set. +
+
+ TYPE:
+ |
+
+ r2
+ |
+
+
+
+ Link line radius end position for sector_pos2. +If None, lowest radius position of track in target sector is set. +
+
+ TYPE:
+ |
+
+ color
+ |
+
+
+
+ Link line color +
+
+ TYPE:
+ |
+
+ height_ratio
+ |
+
+
+
+ Bezier curve height ratio +
+
+ TYPE:
+ |
+
+ direction
+ |
+
+
+
+
+
+ TYPE:
+ |
+
+ arrow_height
+ |
+
+
+
+ Arrow height size (Radius unit) +
+
+ TYPE:
+ |
+
+ arrow_width
+ |
+
+
+
+ Arrow width size (Degree unit) +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
colorbar(
+ bounds: tuple[float, float, float, float] = (1.02, 0.3, 0.02, 0.4),
+ *,
+ vmin: float = 0,
+ vmax: float = 1,
+ cmap: str | Colormap = "bwr",
+ orientation: str = "vertical",
+ label: str | None = None,
+ colorbar_kws: dict[str, Any] | None = None,
+ label_kws: dict[str, Any] | None = None,
+ tick_kws: dict[str, Any] | None = None
+) -> None
+
Plot colorbar
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ bounds
+ |
+
+
+
+ Colorbar bounds tuple (
+
+ TYPE:
+ |
+
+ vmin
+ |
+
+
+
+ Colorbar min value +
+
+ TYPE:
+ |
+
+ vmax
+ |
+
+
+
+ Colorbar max value +
+
+ TYPE:
+ |
+
+ cmap
+ |
+
+
+
+ Colormap (e.g.
+
+ TYPE:
+ |
+
+ orientation
+ |
+
+
+
+ Colorbar orientation (
+
+ TYPE:
+ |
+
+ label
+ |
+
+
+
+ Colorbar label. If None, no label shown. +
+
+ TYPE:
+ |
+
+ colorbar_kws
+ |
+
+
+
+ Colorbar properties (e.g.
+
+ TYPE:
+ |
+
+ label_kws
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
+ tick_kws
+ |
+
+
+
+ Axes.tick_params properties (e.g.
+
+ TYPE:
+ |
+
plotfig(
+ dpi: int = 100, *, ax: PolarAxes | None = None, figsize: tuple[float, float] = (8, 8)
+) -> Figure
+
Plot figure
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ dpi
+ |
+
+
+
+ Figure DPI +
+
+ TYPE:
+ |
+
+ ax
+ |
+
+
+
+ If None, figure and axes are newly created. +
+
+ TYPE:
+ |
+
+ figsize
+ |
+
+
+
+ Figure size +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ figure
+ |
+
+
+
+ Circos matplotlib figure +
+
+ TYPE:
+ |
+
savefig(
+ savefile: str | Path,
+ *,
+ dpi: int = 100,
+ figsize: tuple[float, float] = (8, 8),
+ pad_inches: float = 0.5
+) -> None
+
Save figure to file
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ savefile
+ |
+
+
+
+ Save file (
+
+ TYPE:
+ |
+
+ dpi
+ |
+
+
+
+ DPI +
+
+ TYPE:
+ |
+
+ figsize
+ |
+
+
+
+ Figure size +
+
+ TYPE:
+ |
+
+ pad_inches
+ |
+
+
+
+ Padding inches +
+
+ TYPE:
+ |
+
To plot a figure that settings a user-defined legend, subtracks, or annotations,
+call fig.savefig()
instead of gv.savefig()
.
Sector(
+ name: str,
+ size: float | tuple[float, float],
+ rad_lim: tuple[float, float],
+ clockwise: bool = True,
+)
+
Circos Sector Class
+ + + +PARAMETER | +DESCRIPTION | +
---|---|
+ name
+ |
+
+
+
+ Sector name +
+
+ TYPE:
+ |
+
+ size
+ |
+
+
+
+ Sector size (or range) +
+
+ TYPE:
+ |
+
+ rad_lim
+ |
+
+
+
+ Sector radian limit region +
+
+ TYPE:
+ |
+
+ clockwise
+ |
+
+
+
+ Sector coordinate direction (clockwise or anti-clockwise). +
+
+ TYPE:
+ |
+
property
+
+
+Sector start position (x coordinate)
+property
+
+
+Sector center position (x coordinate)
+property
+
+
+Sector radian limit
+property
+
+
+Sector degree limit
+property
+
+
+Sector coordinate direction
+property
+
+
+Plot functions
+add_track(
+ r_lim: tuple[float, float], *, r_pad_ratio: float = 0, name: str | None = None
+) -> Track
+
Add track to sector
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ r_lim
+ |
+
+
+
+ Radius limit region (0 - 100) +
+
+ TYPE:
+ |
+
+ r_pad_ratio
+ |
+
+
+
+ Radius padding ratio for plot data (0 - 1.0) +
+
+ TYPE:
+ |
+
+ name
+ |
+
+
+
+ Track name. If None,
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ track
+ |
+
+
+
+ Track +
+
+ TYPE:
+ |
+
Get track by name
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ name
+ |
+
+
+
+ Track name +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ track
+ |
+
+
+
+ Target name track +
+
+ TYPE:
+ |
+
Get lowest radius position of sector from tracks data
+ + +RETURNS | +DESCRIPTION | +
---|---|
+ lowest_r
+ |
+
+
+
+ Lowest radius position. If no tracks found,
+
+ TYPE:
+ |
+
Convert x coordinate to radian in sector start-end range
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ x
+ |
+
+
+
+ X coordinate +
+
+ TYPE:
+ |
+
+ ignore_range_error
+ |
+
+
+
+ Ignore x coordinate range error +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ rad
+ |
+
+
+
+ Radian coordinate +
+
+ TYPE:
+ |
+
Plot axis
+By default, simple black axis params(fc="none", ec="black", lw=0.5
) are set.
PARAMETER | +DESCRIPTION | +
---|---|
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
text(
+ text: str,
+ x: float | None = None,
+ r: float = 105,
+ *,
+ adjust_rotation: bool = True,
+ orientation: str = "horizontal",
+ ignore_range_error: bool = False,
+ **kwargs
+) -> None
+
Plot text
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ text
+ |
+
+
+
+ Text content +
+
+ TYPE:
+ |
+
+ x
+ |
+
+
+
+ X position. If None, sector center x is set. +
+
+ TYPE:
+ |
+
+ r
+ |
+
+
+
+ Radius position. By default, outer position
+
+ TYPE:
+ |
+
+ adjust_rotation
+ |
+
+
+
+ If True, text rotation is auto set based on
+
+ TYPE:
+ |
+
+ orientation
+ |
+
+
+
+ Text orientation (
+
+ TYPE:
+ |
+
+ ignore_range_error
+ |
+
+
+
+ If True, ignore x position range error
+(ErrorCase:
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
line(
+ *,
+ r: float | tuple[float, float],
+ start: float | None = None,
+ end: float | None = None,
+ arc: bool = True,
+ **kwargs
+) -> None
+
Plot line
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ r
+ |
+
+
+
+ Line radius position (0 - 100). If r is float, (r, r) is set. +
+
+ TYPE:
+ |
+
+ start
+ |
+
+
+
+ Start position (x coordinate). If None,
+
+ TYPE:
+ |
+
+ end
+ |
+
+
+
+ End position (x coordinate). If None,
+
+ TYPE:
+ |
+
+ arc
+ |
+
+
+
+ If True, plot arc style line for polar projection. +If False, simply plot linear style line. +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
rect(
+ start: float | None = None,
+ end: float | None = None,
+ r_lim: tuple[float, float] | None = None,
+ **kwargs
+) -> None
+
Plot rectangle
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ start
+ |
+
+
+
+ Start position (x coordinate). If None,
+
+ TYPE:
+ |
+
+ end
+ |
+
+
+
+ End position (x coordinate). If None,
+
+ TYPE:
+ |
+
+ r_lim
+ |
+
+
+
+ Radius limit region. If None, (0, 100) is set. +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
raster(
+ img: str | Path | Image.Image,
+ *,
+ size: float = 0.05,
+ x: float | None = None,
+ r: float = 105,
+ rotation: int | float | str | None = None,
+ border_width: int = 0,
+ label: str | None = None,
+ label_pos: str = "bottom",
+ label_margin: float = 0.1,
+ imshow_kws: dict[str, Any] | None = None,
+ text_kws: dict[str, Any] | None = None
+) -> None
+
Plot raster image
+This method is experimental. API may change in the future release.
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ img
+ |
+
+
+
+ Image data (
+
+ TYPE:
+ |
+
+ size
+ |
+
+
+
+ Image size (ratio to overall figure size) +
+
+ TYPE:
+ |
+
+ x
+ |
+
+
+
+ X position. If None, sector center x position is set. +
+
+ TYPE:
+ |
+
+ r
+ |
+
+
+
+ Radius position +
+
+ TYPE:
+ |
+
+ rotation
+ |
+
+
+
+ Image rotation setting.
+If
+
+ TYPE:
+ |
+
+ border_width
+ |
+
+
+
+ Border width in pixel. By default, 0 is set (no border shown). +
+
+ TYPE:
+ |
+
+ label
+ |
+
+
+
+ Image label. If None, no label shown. +
+
+ TYPE:
+ |
+
+ label_pos
+ |
+
+
+
+ Label plot position (
+
+ TYPE:
+ |
+
+ label_margin
+ |
+
+
+
+ Label margin +
+
+ TYPE:
+ |
+
+ imshow_kws
+ |
+
+
+
+ Axes.imshow properties +https://matplotlib.org/stable/api/_as_gen/matplotlib.pyplot.imshow.html +
+
+ TYPE:
+ |
+
+ text_kws
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
Circos Track Class
+ + + +PARAMETER | +DESCRIPTION | +
---|---|
+ name
+ |
+
+
+
+ Track name +
+
+ TYPE:
+ |
+
+ r_lim
+ |
+
+
+
+ Track radius limit region +
+
+ TYPE:
+ |
+
+ r_pad_ratio
+ |
+
+
+
+ Track padding ratio for plot data +
+
+ TYPE:
+ |
+
+ parent_sector
+ |
+
+
+
+ Parent sector of track +
+
+ TYPE:
+ |
+
property
+
+
+Track start position (x coordinate)
+property
+
+
+Track center position (x coordinate)
+property
+
+
+Track radius limit
+property
+
+
+Track radius size for plot data (r_size
with padding)
property
+
+
+Track radius limit for plot data (r_lim
with padding)
property
+
+
+Track radian limit
+property
+
+
+Track degree limit
+property
+
+
+Track coordinate direction
+property
+
+
+Plot functions
+Convert x coordinate to radian in track start-end range
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ x
+ |
+
+
+
+ X coordinate +
+
+ TYPE:
+ |
+
+ ignore_range_error
+ |
+
+
+
+ Ignore x coordinate range error +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ rad
+ |
+
+
+
+ Radian coordinate +
+
+ TYPE:
+ |
+
Plot axis
+By default, simple black axis params(fc="none", ec="black", lw=0.5
) are set.
PARAMETER | +DESCRIPTION | +
---|---|
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
text(
+ text: str,
+ x: float | None = None,
+ r: float | None = None,
+ *,
+ adjust_rotation: bool = True,
+ orientation: str = "horizontal",
+ ignore_range_error: bool = False,
+ **kwargs
+) -> None
+
Plot text
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ text
+ |
+
+
+
+ Text content +
+
+ TYPE:
+ |
+
+ x
+ |
+
+
+
+ X position. If None, track center x position is set. +
+
+ TYPE:
+ |
+
+ r
+ |
+
+
+
+ Radius position. If None, track center radius position is set. +
+
+ TYPE:
+ |
+
+ adjust_rotation
+ |
+
+
+
+ If True, text rotation is auto set based on
+
+ TYPE:
+ |
+
+ orientation
+ |
+
+
+
+ Text orientation (
+
+ TYPE:
+ |
+
+ ignore_range_error
+ |
+
+
+
+ If True, ignore x position range error
+(ErrorCase:
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
rect(
+ start: float,
+ end: float,
+ *,
+ r_lim: tuple[float, float] | None = None,
+ ignore_pad: bool = False,
+ **kwargs
+) -> None
+
Plot rectangle
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ start
+ |
+
+
+
+ Start position (x coordinate) +
+
+ TYPE:
+ |
+
+ end
+ |
+
+
+
+ End position (x coordinate) +
+
+ TYPE:
+ |
+
+ r_lim
+ |
+
+
+
+ Radius limit range.
+If None,
+
+ TYPE:
+ |
+
+ ignore_pad
+ |
+
+
+
+ If True, ignore track padding setting.
+If
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
arrow(
+ start: float,
+ end: float,
+ *,
+ r_lim: tuple[float, float] | None = None,
+ head_length: float = 2,
+ shaft_ratio: float = 0.5,
+ **kwargs
+) -> None
+
Plot arrow
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ start
+ |
+
+
+
+ Start position (x coordinate) +
+
+ TYPE:
+ |
+
+ end
+ |
+
+
+
+ End position (x coordinate) +
+
+ TYPE:
+ |
+
+ r_lim
+ |
+
+
+
+ Radius limit range. If None,
+
+ TYPE:
+ |
+
+ head_length
+ |
+
+
+
+ Arrow head length (Degree unit) +
+
+ TYPE:
+ |
+
+ shaft_ratio
+ |
+
+
+
+ Arrow shaft ratio (0 - 1.0) +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
xticks(
+ x: list[int] | list[float] | np.ndarray,
+ labels: list[str] | None = None,
+ *,
+ tick_length: float = 2,
+ outer: bool = True,
+ show_bottom_line: bool = False,
+ label_size: float = 8,
+ label_margin: float = 0.5,
+ label_orientation: str = "horizontal",
+ line_kws: dict[str, Any] | None = None,
+ text_kws: dict[str, Any] | None = None
+) -> None
+
Plot xticks & labels on user-specified position
+If you want to plot xticks and their position labels at regular intervals,
+it is recommended to use track.xticks_by_interval()
instead.
PARAMETER | +DESCRIPTION | +
---|---|
+ x
+ |
+
+
+
+ X coordinates +
+
+ TYPE:
+ |
+
+ labels
+ |
+
+
+
+ Labels on xticks. If None, only plot ticks line. +
+
+ TYPE:
+ |
+
+ tick_length
+ |
+
+
+
+ Tick length (Radius unit) +
+
+ TYPE:
+ |
+
+ outer
+ |
+
+
+
+ If True, show ticks on outer. If False, show ticks on inner. +
+
+ TYPE:
+ |
+
+ show_bottom_line
+ |
+
+
+
+ If True, show bottom line. +
+
+ TYPE:
+ |
+
+ label_size
+ |
+
+
+
+ Label size +
+
+ TYPE:
+ |
+
+ label_margin
+ |
+
+
+
+ Label margin size +
+
+ TYPE:
+ |
+
+ label_orientation
+ |
+
+
+
+ Label orientation (
+
+ TYPE:
+ |
+
+ line_kws
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
+ text_kws
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
xticks_by_interval(
+ interval: int | float,
+ *,
+ tick_length: float = 2,
+ outer: bool = True,
+ show_bottom_line: bool = False,
+ show_label: bool = True,
+ show_endlabel: bool = True,
+ label_size: float = 8,
+ label_margin: float = 0.5,
+ label_orientation: str = "horizontal",
+ label_formatter: Callable[[float], str] | None = None,
+ line_kws: dict[str, Any] | None = None,
+ text_kws: dict[str, Any] | None = None
+) -> None
+
Plot xticks & position labels by user-specified interval
+track.xticks_by_interval()
is high-level API function of track.xticks()
.
+If you want to plot xticks and their labels in any position you like,
+use track.xticks()
instead.
PARAMETER | +DESCRIPTION | +
---|---|
+ interval
+ |
+
+
+
+ Xticks interval +
+
+ TYPE:
+ |
+
+ tick_length
+ |
+
+
+
+ Tick length (Radius unit) +
+
+ TYPE:
+ |
+
+ outer
+ |
+
+
+
+ If True, show ticks on outer. If False, show ticks on inner. +
+
+ TYPE:
+ |
+
+ show_bottom_line
+ |
+
+
+
+ If True, show bottom line. +
+
+ TYPE:
+ |
+
+ show_label
+ |
+
+
+
+ If True, show label of xticks interval position. +
+
+ TYPE:
+ |
+
+ show_endlabel
+ |
+
+
+
+ If False, no display end xtick label. +Used to prevent overlap of start-end xtick labels. +
+
+ TYPE:
+ |
+
+ label_size
+ |
+
+
+
+ Label size +
+
+ TYPE:
+ |
+
+ label_margin
+ |
+
+
+
+ Label margin size +
+
+ TYPE:
+ |
+
+ label_orientation
+ |
+
+
+
+ Label orientation (
+
+ TYPE:
+ |
+
+ label_formatter
+ |
+
+
+
+ User-defined function for label format. (e.g.
+
+ TYPE:
+ |
+
+ line_kws
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
+ text_kws
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
yticks(
+ y: list[int] | list[float] | np.ndarray,
+ labels: list[str] | None = None,
+ *,
+ vmin: float = 0,
+ vmax: float | None = None,
+ side: str = "right",
+ tick_length: float = 1,
+ label_size: float = 8,
+ label_margin: float = 0.5,
+ line_kws: dict[str, Any] | None = None,
+ text_kws: dict[str, Any] | None = None
+) -> None
+
Plot yticks & labels on user-specified position
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ y
+ |
+
+
+
+ Y coordinates +
+
+ TYPE:
+ |
+
+ labels
+ |
+
+
+
+ Labels on yticks. If None, only plot ticks line. +
+
+ TYPE:
+ |
+
+ vmin
+ |
+
+
+
+ Y min value +
+
+ TYPE:
+ |
+
+ vmax
+ |
+
+
+
+ Y max value. If None,
+
+ TYPE:
+ |
+
+ side
+ |
+
+
+
+ Ticks side position (
+
+ TYPE:
+ |
+
+ tick_length
+ |
+
+
+
+ Tick length (Degree unit) +
+
+ TYPE:
+ |
+
+ label_size
+ |
+
+
+
+ Label size +
+
+ TYPE:
+ |
+
+ label_margin
+ |
+
+
+
+ Label margin size +
+
+ TYPE:
+ |
+
+ line_kws
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
+ text_kws
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
Plot grid
+By default, color="grey", alpha=0.5, zorder=0
line params are set.
PARAMETER | +DESCRIPTION | +
---|---|
+ y_grid_num
+ |
+
+
+
+ Y-axis grid line number. If None, y-axis grid line is not shown. +
+
+ TYPE:
+ |
+
+ x_grid_interval
+ |
+
+
+
+ X-axis grid line interval. If None, x-axis grid line is not shown. +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Axes.plot properties (e.g.
+
+ TYPE:
+ |
+
line(
+ x: list[float] | np.ndarray,
+ y: list[float] | np.ndarray,
+ *,
+ vmin: float = 0,
+ vmax: float | None = None,
+ arc: bool = True,
+ **kwargs
+) -> None
+
Plot line
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ x
+ |
+
+
+
+ X coordinates +
+
+ TYPE:
+ |
+
+ y
+ |
+
+
+
+ Y coordinates +
+
+ TYPE:
+ |
+
+ vmin
+ |
+
+
+
+ Y min value +
+
+ TYPE:
+ |
+
+ vmax
+ |
+
+
+
+ Y max value. If None,
+
+ TYPE:
+ |
+
+ arc
+ |
+
+
+
+ If True, plot arc style line for polar projection. +If False, simply plot linear style line. +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Axes.plot properties (e.g.
+
+ TYPE:
+ |
+
scatter(
+ x: list[float] | np.ndarray,
+ y: list[float] | np.ndarray,
+ *,
+ vmin: float = 0,
+ vmax: float | None = None,
+ **kwargs
+) -> None
+
Plot scatter
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ x
+ |
+
+
+
+ X position list +
+
+ TYPE:
+ |
+
+ y
+ |
+
+
+
+ Y position list +
+
+ TYPE:
+ |
+
+ vmin
+ |
+
+
+
+ Y min value +
+
+ TYPE:
+ |
+
+ vmax
+ |
+
+
+
+ Y max value. If None,
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Axes.scatter properties (e.g.
+
+ TYPE:
+ |
+
bar(
+ x: list[float] | np.ndarray,
+ height: list[float] | np.ndarray,
+ width: float = 0.8,
+ bottom: float | list[float] | np.ndarray = 0,
+ align: str = "center",
+ *,
+ vmin: float = 0,
+ vmax: float | None = None,
+ **kwargs
+) -> None
+
Plot bar
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ x
+ |
+
+
+
+ Bar x coordinates +
+
+ TYPE:
+ |
+
+ height
+ |
+
+
+
+ Bar heights +
+
+ TYPE:
+ |
+
+ width
+ |
+
+
+
+ Bar width +
+
+ TYPE:
+ |
+
+ bottom
+ |
+
+
+
+ Bar bottom(s) +
+
+ TYPE:
+ |
+
+ align
+ |
+
+
+
+ Bar alignment type (
+
+ TYPE:
+ |
+
+ vmin
+ |
+
+
+
+ Y min value +
+
+ TYPE:
+ |
+
+ vmax
+ |
+
+
+
+ Y max value. If None,
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Axes.bar properties (e.g.
+
+ TYPE:
+ |
+
stacked_bar(
+ table_data: str | Path | pd.DataFrame | StackedBarTable,
+ *,
+ delimiter: str = "\t",
+ width: float = 0.6,
+ cmap: str | dict[str, str] = "tab10",
+ vmax: float | None = None,
+ show_label: bool = True,
+ label_pos: str = "bottom",
+ label_margin: float = 2,
+ bar_kws: dict[str, Any] | None = None,
+ label_kws: dict[str, Any] | None = None
+) -> StackedBarTable
+
Plot stacked bar from table data
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ table_data
+ |
+
+
+
+ Table file or Table DataFrame or StackedBarTable +
+
+ TYPE:
+ |
+
+ delimiter
+ |
+
+
+
+ Table file delimiter +
+
+ TYPE:
+ |
+
+ width
+ |
+
+
+
+ Bar width ratio (0.0 - 1.0) +
+
+ TYPE:
+ |
+
+ cmap
+ |
+
+
+
+ Colormap assigned to each stacked bar.
+User can set matplotlib's colormap (e.g.
+
+ TYPE:
+ |
+
+ vmax
+ |
+
+
+
+ Stacked bar max value. +If None, max value in each row values sum is set. +
+
+ TYPE:
+ |
+
+ show_label
+ |
+
+
+
+ Show table row names as labels +
+
+ TYPE:
+ |
+
+ label_pos
+ |
+
+
+
+ Label position (
+
+ TYPE:
+ |
+
+ label_margin
+ |
+
+
+
+ Label margin size +
+
+ TYPE:
+ |
+
+ bar_kws
+ |
+
+
+
+ Axes.bar properties (e.g.
+
+ TYPE:
+ |
+
+ label_kws
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ sb_table
+ |
+
+
+
+ Stacked bar table +
+
+ TYPE:
+ |
+
stacked_barh(
+ table_data: str | Path | pd.DataFrame | StackedBarTable,
+ *,
+ delimiter: str = "\t",
+ width: float = 0.6,
+ cmap: str | dict[str, str] = "tab10",
+ bar_kws: dict[str, Any] | None = None
+) -> StackedBarTable
+
Plot horizontal stacked bar from table data
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ table_data
+ |
+
+
+
+ Table file or Table DataFrame or StackedBarTable +
+
+ TYPE:
+ |
+
+ delimiter
+ |
+
+
+
+ Table file delimiter +
+
+ TYPE:
+ |
+
+ width
+ |
+
+
+
+ Bar width ratio (0.0 - 1.0) +
+
+ TYPE:
+ |
+
+ cmap
+ |
+
+
+
+ Colormap assigned to each stacked bar.
+User can set matplotlib's colormap (e.g.
+
+ TYPE:
+ |
+
+ bar_kws
+ |
+
+
+
+ Patch properties for bar plot (e.g.
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ sb_table
+ |
+
+
+
+ Stacked bar table +
+
+ TYPE:
+ |
+
fill_between(
+ x: list[float] | np.ndarray,
+ y1: list[float] | np.ndarray,
+ y2: float | list[float] | np.ndarray = 0,
+ *,
+ vmin: float = 0,
+ vmax: float | None = None,
+ arc: bool = True,
+ **kwargs
+) -> None
+
Fill the area between two horizontal(y1, y2) curves
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ x
+ |
+
+
+
+ X coordinates +
+
+ TYPE:
+ |
+
+ y1
+ |
+
+
+
+ Y coordinates (first curve definition) +
+
+ TYPE:
+ |
+
+ y2
+ |
+
+
+
+ Y coordinate[s] (second curve definition) +
+
+ TYPE:
+ |
+
+ vmin
+ |
+
+
+
+ Y min value +
+
+ TYPE:
+ |
+
+ vmax
+ |
+
+
+
+ Y max value. If None,
+
+ TYPE:
+ |
+
+ arc
+ |
+
+
+
+ If True, plot arc style line for polar projection. +If False, simply plot linear style line. +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Axes.fill_between properties (e.g.
+
+ TYPE:
+ |
+
heatmap(
+ data: list | np.ndarray,
+ *,
+ vmin: float | None = None,
+ vmax: float | None = None,
+ start: float | None = None,
+ end: float | None = None,
+ width: float | None = None,
+ cmap: str | Colormap = "bwr",
+ show_value: bool = False,
+ rect_kws: dict[str, Any] | None = None,
+ text_kws: dict[str, Any] | None = None
+) -> None
+
Plot heatmap
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ data
+ |
+
+
+
+ Numerical list, numpy 1d or 2d array +
+
+ TYPE:
+ |
+
+ vmin
+ |
+
+
+
+ Min value for heatmap plot. If None,
+
+ TYPE:
+ |
+
+ vmax
+ |
+
+
+
+ Max value for heatmap plot. If None,
+
+ TYPE:
+ |
+
+ start
+ |
+
+
+
+ Start position for heatmap plot (x coordinate).
+If None,
+
+ TYPE:
+ |
+
+ end
+ |
+
+
+
+ End position for heatmap plot (x coordinate).
+If None,
+
+ TYPE:
+ |
+
+ width
+ |
+
+
+
+ Heatmap rectangle x width size.
+Normally heatmap plots squares of equal width. In some cases,
+it is necessary to reduce the width of only the last column data square.
+At that time, width can be set under the following conditions.
+
+
+ TYPE:
+ |
+
+ cmap
+ |
+
+
+
+ Colormap (e.g.
+
+ TYPE:
+ |
+
+ show_value
+ |
+
+
+
+ If True, show data value on heatmap rectangle +
+
+ TYPE:
+ |
+
+ rect_kws
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
+ text_kws
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
raster(
+ img: str | Path | Image.Image,
+ *,
+ w: float = 1.0,
+ h: float = 1.0,
+ rotate: bool = True,
+ **kwargs
+) -> None
+
Plot raster image
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ img
+ |
+
+
+
+ Image data (
+
+ TYPE:
+ |
+
+ w
+ |
+
+
+
+ Width ratio (
+
+ TYPE:
+ |
+
+ h
+ |
+
+
+
+ Height ratio (
+
+ TYPE:
+ |
+
+ rotate
+ |
+
+
+
+ If True, rotate image 180 degrees if track is in lower location
+(
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Axes.pcolormesh properties +https://matplotlib.org/stable/api/_as_gen/matplotlib.axes.Axes.pcolormesh.html +
+
+ TYPE:
+ |
+
tree(
+ tree_data: str | Path | Tree,
+ *,
+ format: str = "newick",
+ outer: bool = True,
+ align_leaf_label: bool = True,
+ ignore_branch_length: bool = False,
+ leaf_label_size: float = 12,
+ leaf_label_rmargin: float = 2.0,
+ reverse: bool = False,
+ ladderize: bool = False,
+ line_kws: dict[str, Any] | None = None,
+ align_line_kws: dict[str, Any] | None = None,
+ label_formatter: Callable[[str], str] | None = None
+) -> TreeViz
+
Plot tree
+It is recommended that the track(sector) size be the same as the number of
+leaf nodes in the tree, to make it easier to combine with bar
and heatmap
.
PARAMETER | +DESCRIPTION | +
---|---|
+ tree_data
+ |
+
+
+
+ Tree data (
+
+ TYPE:
+ |
+
+ format
+ |
+
+
+
+ Tree format (
+
+ TYPE:
+ |
+
+ outer
+ |
+
+
+
+ If True, plot tree on outer side. If False, plot tree on inner side. +
+
+ TYPE:
+ |
+
+ align_leaf_label
+ |
+
+
+
+ If True, align leaf label. +
+
+ TYPE:
+ |
+
+ ignore_branch_length
+ |
+
+
+
+ If True, ignore branch length for plotting tree. +
+
+ TYPE:
+ |
+
+ leaf_label_size
+ |
+
+
+
+ Leaf label size +
+
+ TYPE:
+ |
+
+ leaf_label_rmargin
+ |
+
+
+
+ Leaf label radius margin +
+
+ TYPE:
+ |
+
+ reverse
+ |
+
+
+
+ If True, reverse tree +
+
+ TYPE:
+ |
+
+ ladderize
+ |
+
+
+
+ If True, ladderize tree +
+
+ TYPE:
+ |
+
+ line_kws
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
+ align_line_kws
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
+ label_formatter
+ |
+
+
+
+ User-defined label text format function to change plot label text content.
+For example, if you want to change underscore of the label to space,
+set
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ tv
+ |
+
+
+
+ TreeViz instance +
+
+ TYPE:
+ |
+
genomic_features(
+ features: SeqFeature | list[SeqFeature],
+ *,
+ plotstyle: str = "box",
+ r_lim: tuple[float, float] | None = None,
+ facecolor_handler: Callable[[SeqFeature], str] | None = None,
+ **kwargs
+) -> None
+
Plot genomic features
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ features
+ |
+
+
+
+ Biopython's SeqFeature or SeqFeature list +
+
+ TYPE:
+ |
+
+ plotstyle
+ |
+
+
+
+ Plot style (
+
+ TYPE:
+ |
+
+ r_lim
+ |
+
+
+
+ Radius limit range. If None,
+
+ TYPE:
+ |
+
+ facecolor_handler
+ |
+
+
+
+ User-defined function to handle facecolor +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
TreeViz(
+ tree_data: str | Path | Tree,
+ *,
+ format: str = "newick",
+ outer: bool = True,
+ align_leaf_label: bool = True,
+ ignore_branch_length: bool = False,
+ leaf_label_size: float = 12,
+ leaf_label_rmargin: float = 2.0,
+ reverse: bool = False,
+ ladderize: bool = False,
+ line_kws: dict[str, Any] | None = None,
+ align_line_kws: dict[str, Any] | None = None,
+ label_formatter: Callable[[str], str] | None = None,
+ track: Track
+)
+
Phylogenetic Tree Visualization Class
+Interface for changing tree properties and adding tree annotations in a track
+ + + +PARAMETER | +DESCRIPTION | +
---|---|
+ tree_data
+ |
+
+
+
+ Tree data (
+
+ TYPE:
+ |
+
+ format
+ |
+
+
+
+ Tree format (
+
+ TYPE:
+ |
+
+ outer
+ |
+
+
+
+ If True, plot tree on outer side. If False, plot tree on inner side. +
+
+ TYPE:
+ |
+
+ align_leaf_label
+ |
+
+
+
+ If True, align leaf label. +
+
+ TYPE:
+ |
+
+ ignore_branch_length
+ |
+
+
+
+ If True, ignore branch length for plotting tree. +
+
+ TYPE:
+ |
+
+ leaf_label_size
+ |
+
+
+
+ Leaf label size +
+
+ TYPE:
+ |
+
+ leaf_label_rmargin
+ |
+
+
+
+ Leaf label radius margin +
+
+ TYPE:
+ |
+
+ reverse
+ |
+
+
+
+ If True, reverse tree +
+
+ TYPE:
+ |
+
+ ladderize
+ |
+
+
+
+ If True, ladderize tree +
+
+ TYPE:
+ |
+
+ line_kws
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
+ align_line_kws
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
+ label_formatter
+ |
+
+
+
+ User-defined label text format function to change plot label text content.
+For example, if you want to change underscore of the label to space,
+set
+
+ TYPE:
+ |
+
+ track
+ |
+
+
+
+ Track for tree visualization +
+
+ TYPE:
+ |
+
cached
+ property
+
+
+Leaf labels
+cached
+ property
+
+
+Internal node labels
+cached
+ property
+
+
+All node labels
+cached
+ property
+
+
+Max tree depth (root -> leaf max branch length)
+cached
+ property
+
+
+Tree node name & node xr coordinate dict
+cached
+ property
+
+
+Tree node name & rectangle dict
+staticmethod
+
+
+Load tree data
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ data
+ |
+
+
+
+ Tree data +
+
+ TYPE:
+ |
+
+ format
+ |
+
+
+
+ Tree format +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ tree
+ |
+
+
+
+ Tree object +
+
+ TYPE:
+ |
+
Search target node name from query
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ query
+ |
+
+
+
+ Search query node name(s). If multiple node names are set, +MRCA(Most Recent Common Ancester) node is set. +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ target_node_name
+ |
+
+
+
+ Target node name +
+
+ TYPE:
+ |
+
Get target node x limit by query
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ query
+ |
+
+
+
+ Search query node name(s) for getting x limit. +If multiple node names are set, +MRCA(Most Recent Common Ancester) node is set. +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ xlim
+ |
+
+
+
+ X limit tuple +
+
+ TYPE:
+ |
+
show_confidence(
+ *,
+ size: float = 8,
+ orientation: str = "vertical",
+ label_formatter: Callable[[float], str] | None = None,
+ **kwargs
+) -> None
+
Show confidence value on each internal node of the phylogenetic tree
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ size
+ |
+
+
+
+ Text size +
+
+ TYPE:
+ |
+
+ orientation
+ |
+
+
+
+ Text orientation (
+
+ TYPE:
+ |
+
+ label_formatter
+ |
+
+
+
+ User-defined function for label format. +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
highlight(
+ query: str | list[str] | tuple[str], *, color: str, alpha: float = 0.5, **kwargs
+) -> None
+
Plot highlight for target node
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ query
+ |
+
+
+
+ Search query node name(s) for highlight. If multiple node names are set, +MRCA(Most Recent Common Ancester) node is set. +
+
+ TYPE:
+ |
+
+ color
+ |
+
+
+
+ Highlight color +
+
+ TYPE:
+ |
+
+ alpha
+ |
+
+
+
+ Highlight color alpha(transparancy) value +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
marker(
+ query: str | list[str] | tuple[str],
+ *,
+ marker: str = "o",
+ size: int = 6,
+ descendent: bool = True,
+ **kwargs
+) -> None
+
Plot marker on target node(s)
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ query
+ |
+
+
+
+ Search query node name(s) for plotting marker. +If multiple node names are set, +MRCA(Most Recent Common Ancester) node is set. +
+
+ TYPE:
+ |
+
+ marker
+ |
+
+
+
+ Marker type (e.g.
+
+ TYPE:
+ |
+
+ size
+ |
+
+
+
+ Marker size +
+
+ TYPE:
+ |
+
+ descendent
+ |
+
+
+
+ If True, plot markers on target node's descendent as well. +
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Axes.scatter properties (e.g.
+
+ TYPE:
+ |
+
Set tree node label properties
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ target_node_label
+ |
+
+
+
+ Target node label name +
+
+ TYPE:
+ |
+
+ kwargs
+ |
+
+
+
+ Text properties (e.g.
+
+ TYPE:
+ |
+
set_node_line_props(
+ query: str | list[str] | tuple[str],
+ *,
+ descendent: bool = True,
+ apply_label_color: bool = False,
+ **kwargs
+) -> None
+
Set tree node line properties
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ query
+ |
+
+
+
+ Search query node name(s) for coloring tree node line. +If multiple node names are set, +MRCA(Most Recent Common Ancester) node is set. +
+
+ TYPE:
+ |
+
+ descendent
+ |
+
+
+
+ If True, set properties on target node's descendent as well. +
+
+ TYPE:
+ |
+
+ apply_label_color
+ |
+
+
+
+ If True &
+
+ TYPE:
+ |
+
+ **kwargs
+ |
+
+
+
+ Patch properties (e.g.
+
+ TYPE:
+ |
+
load_prokaryote_example_file(
+ filename: str, cache_dir: str | Path | None = None, overwrite_cache: bool = False
+) -> Path
+
Load pycirclize example Genbank or GFF file
+Load example file from https://github.com/moshi4/pycirclize-data/
+and cache file in local directory (Default: ~/.cache/pycirclize/
).
List of example Genbank or GFF filename
+enterobacteria_phage.[gbk|gff]
mycoplasma_alvi.[gbk|gff]
escherichia_coli.[gbk|gff].gz
PARAMETER | +DESCRIPTION | +
---|---|
+ filename
+ |
+
+
+
+ Genbank or GFF filename (e.g.
+
+ TYPE:
+ |
+
+ cache_dir
+ |
+
+
+
+ Output cache directory (Default:
+
+ TYPE:
+ |
+
+ overwrite_cache
+ |
+
+
+
+ If True, overwrite cache file. +Assumed to be used when cache file is corrupt. +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ file_path
+ |
+
+
+
+ Genbank or GFF file +
+
+ TYPE:
+ |
+
load_eukaryote_example_dataset(
+ name: str = "hg38",
+ cache_dir: str | Path | None = None,
+ overwrite_cache: bool = False,
+) -> tuple[Path, Path, list[ChrLink]]
+
Load pycirclize eukaryote example dataset
+Load example file from https://github.com/moshi4/pycirclize-data/
+and cache file in local directory (Default: ~/.cache/pycirclize/
).
List of dataset contents (download from UCSC)
+chr1 0 248956422
)chr1 0 2300000 p36.33 gneg
)chr1 1000 4321 chr3 8000 5600
)PARAMETER | +DESCRIPTION | +
---|---|
+ name
+ |
+
+
+
+ Dataset name (
+
+ TYPE:
+ |
+
+ cache_dir
+ |
+
+
+
+ Output cache directory (Default:
+
+ TYPE:
+ |
+
+ overwrite_cache
+ |
+
+
+
+ If True, overwrite cache dataset. +Assumed to be used when cache dataset is corrupt. +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ chr_bed_file
+ |
+
+
+
+ BED file +
+
+ TYPE:
+ |
+
+ cytoband_file
+ |
+
+
+
+ Cytoband file +
+
+ TYPE:
+ |
+
+ chr_links
+ |
+
+
+
+ Chromosome links +
+
+ TYPE:
+ |
+
Load example phylogenetic tree file
+List of example tree filename
+small_example.nwk
(7 species)medium_example.nwk
(21 species)large_example.nwk
(190 species)alphabet.nwk
(26 species)PARAMETER | +DESCRIPTION | +
---|---|
+ filename
+ |
+
+
+
+ Target filename +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ tree_file
+ |
+
+
+
+ Tree file (Newick format) +
+
+ TYPE:
+ |
+
Load example image file from local package data
+e.g. python_logo.png
PARAMETER | +DESCRIPTION | +
---|---|
+ filename
+ |
+
+
+
+ Image file name +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ image_file_path
+ |
+
+
+
+ Image file path +
+
+ TYPE:
+ |
+
fetch_genbank_by_accid(
+ accid: str, gbk_outfile: str | Path | None = None, email: str | None = None
+) -> TextIOWrapper
+
Fetch genbank text by Accession ID
PARAMETER | +DESCRIPTION | +
---|---|
+ accid
+ |
+
+
+
+ Accession ID +
+
+ TYPE:
+ |
+
+ gbk_outfile
+ |
+
+
+
+ If file path is set, write fetch data to file +
+
+ TYPE:
+ |
+
+ email
+ |
+
+
+
+ Email address to notify download limitation (Required for bulk download) +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+
+ TextIOWrapper
+
+ |
+
+
+
+ Genbank data + |
+
Examples:
+ + +calc_group_spaces(
+ groups: list[int],
+ *,
+ space_bw_group: float = 15,
+ space_in_group: float = 2,
+ endspace: bool = True
+) -> list[float]
+
Calculate spaces between/within groups
+This function can be used to easily calculate the space size
+when data is separated into multiple groups for display.
+For example, to set up a space to divide [A, B, C, D, E, F, G, H, I, J]
+into three groups such as [(A, B, C, D), (E, F, G), (H, I, J)]
,
+set groups=[4, 3, 3]
.
PARAMETER | +DESCRIPTION | +
---|---|
+ groups
+ |
+
+
+
+ List of each group number (e.g.
+
+ TYPE:
+ |
+
+ space_bw_group
+ |
+
+
+
+ Space size between group +
+
+ TYPE:
+ |
+
+ space_in_group
+ |
+
+
+
+ Space size within group +
+
+ TYPE:
+ |
+
+ endspace
+ |
+
+
+
+ If True, insert space after the end group +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ spaces
+ |
+
+
+
+ Spaces between/within groups +
+
+ TYPE:
+ |
+
Color Cycler Class
+ + + + + + + + + +Get hexcolor cyclically from cmap by counter or user specified number
+ColorCycler()
works same as ColorCycler.get_color()
PARAMETER | +DESCRIPTION | +
---|---|
+ n
+ |
+
+
+
+ Number for color cycle. If None, counter class variable is used. +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ hexcolor
+ |
+
+
+
+ Cyclic hexcolor string +
+
+ TYPE:
+ |
+
classmethod
+
+
+Reset cycle counter
+ +classmethod
+
+
+Set colormap (Default: tab10
)
classmethod
+
+
+Get hexcolor cyclically from cmap by counter or user specified number
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ n
+ |
+
+
+
+ Number for color cycle. If None, counter class variable is used. +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ hexcolor
+ |
+
+
+
+ Cyclic hexcolor string +
+
+ TYPE:
+ |
+
classmethod
+
+
+Get hexcolor list of colormap
+ + +PARAMETER | +DESCRIPTION | +
---|---|
+ n
+ |
+
+
+
+ If n is None, all(=cmap.N) hexcolors are extracted from colormap. +If n is specified, hexcolors are extracted from n equally divided colormap. +
+
+ TYPE:
+ |
+
RETURNS | +DESCRIPTION | +
---|---|
+ hexcolor_list
+ |
+
+
+
+ Hexcolor list +
+
+ TYPE:
+ |
+