Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

circos.nested

Nested zooming with two circular plots


Description

Nested zooming with two circular plots

Usage

circos.nested(
    f1,
    f2,
    correspondance,
    connection_height = mm_h(5),
    connection_col = NA,
    connection_border = "black",
    connection_lty = par("lty"),
    connection_lwd = par("lwd"),
    adjust_start_degree = TRUE)

Arguments

f1

A self-defined function for making the first circular plot. The function should have no argument.

f2

A self-defined function for making the second circular plot. The function should have no argument.

correspondance

A six-column data frame which contains correspondance between the coordinates in two circular plots

connection_height

The height of the connection track, measured as the percent to the radius of the unit circle. The value can be specified by uh or convert_height with absolute units.

connection_col

Filled color of the connection track. The value can be a vector with same length as number of rows of correspondance

connection_border

Border color of the connection track.

connection_lty

Line style of the connection track borders

connection_lwd

Line width of the connection track borders

adjust_start_degree

If circos.par(start.degree = ...) is not set in f2(), the start degree for the second circular plot will be adjusted to make the distance of sectors between the two plots to the minimal.

Details

The function visualizes zoomings by combining two circular plots into one page where one is the normal circular plot and the other one only contains regions that need to be zoomed. This function automatically arranges the two plots to make it easy to correspond between the original and the zoomed sectors.

Since the function needs to know the information of the two circular plots, please do not call circos.clear in either f1() or f2(). It will be called internally in circos.nested.

If adjust_start_degree is set to TRUE, start.degree should not be set in f2(). Also canvas.xlim and canvas.ylim are reset in f2(), they should not be set in f2() either.

Author(s)

Zuguang Gu <z.gu@dkfz.de>

See Also

Examples

# There is no example
NULL

circlize

Circular Visualization

v0.4.12
MIT + file LICENSE
Authors
Zuguang Gu
Initial release
2021-1-8

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.