View source: R/plot_node_ages2.R
plot_node_ages2 | R Documentation |
'plot_node_ages' plots a given chronogram and adds age data [points()] given in 'node_ages' and 'summary_ages' to the corresponding nodes.
plot_node_ages2( chronogram, matched_ages, time_depth = NULL, plot_type = "phyloch", mai1, mai2, mai3, mai4, omi1, omi2, omi3, omi4, title = "Chronogram", cex_title = graphics::par("cex"), pos_title = 1, cex_tiplabels = graphics::par("cex"), geologic_timescale = "strat2012", geologic_unit = "period", pos_axis = 1, cex_axis = graphics::par("cex"), axis_label = "Time (MYA)", center_axislabel = 0.5, cex_axislabel = graphics::par("cex"), pch_type, pch_color, pch_transparency = NULL, pch_cex = graphics::par("cex"), bars_color = "#80808050", bars_lty = "solid", bars_lwd = 7, add_legend = TRUE, legend_cex = cex_axislabel * 0.5, legend_pt_cex = cex_axislabel * 0.5, legend_x, legend_y, legend_box = TRUE, legend_pch, legend_text, legend_color, legend_title, ... )
chronogram |
A 'phylo' object with branch length proportional to time. |
matched_ages |
An output of [datelife:::summary.matchedCalibrations()] with age data matched to nodes in 'chronogram'. |
time_depth |
A numeric vector indicating the upper limit for the time scale on the x axis. |
plot_type |
A character vector of length one indicating the type of plot to generate. Options are:
|
mai1 |
A numeric value indicating internal plot margin sizes in inches. 'mai4' is particularly important as it indicates the space needed for plotting whole tip labels on the right margin of the plot. |
mai2 |
A numeric value indicating internal plot margin sizes in inches. 'mai4' is particularly important as it indicates the space needed for plotting whole tip labels on the right margin of the plot. |
mai3 |
A numeric value indicating internal plot margin sizes in inches. 'mai4' is particularly important as it indicates the space needed for plotting whole tip labels on the right margin of the plot. |
mai4 |
A numeric value indicating internal plot margin sizes in inches. 'mai4' is particularly important as it indicates the space needed for plotting whole tip labels on the right margin of the plot. |
omi1 |
A numeric value indicating outter plot margin sizes in inches. |
omi2 |
A numeric value indicating outter plot margin sizes in inches. |
omi3 |
A numeric value indicating outter plot margin sizes in inches. |
omi4 |
A numeric value indicating outter plot margin sizes in inches. |
title |
A character string providing the title for the plot. |
cex_title |
A numeric indicating character expansion for the title. Default to value given by 'graphics::par("cex")'. |
pos_title |
Indicates the line position of the title. Default to 1. |
cex_tiplabels |
A numeric value indicating **c**haracter **ex**pansion (i.e., size scaling factor) of tip labels in 'chronogram'. Default to value given by 'graphics::par("cex")'. |
geologic_timescale |
A dataframe of geochronological limits. |
geologic_unit |
A character vector used to select geological time units that shall be displayed. When using |
pos_axis |
Indicates the line position of the axis. Default to 1. |
cex_axis |
A numeric indicating character expansion for the axis. Default to value given by 'graphics::par("cex")'. |
axis_label |
A character string used to provide information on time units. Defaults to "Time (MYA)" (time in million years ago). If NULL, time units are not added. |
center_axislabel |
A numeric indicating centering position of time axis label. Default to 0.5. |
cex_axislabel |
A numeric indicating character expansion for the time axis label. Default to value given by 'graphics::par("cex")'. |
pch_type |
A numeric vector or named list indicating the symbol for calibration age points. See [graphics::par()] for symbol options. Defaults to 20 = "bullet circle". |
pch_color |
A named vector or list of colors. Names must correspond to names in 'matched_ages$in_phy$references'. If vector is not named and length > 1, colors will be recycled. |
pch_transparency |
A numeric value ranging from 10-99, indicating color transparency for color defined by 'pch_color'. Default to 'NULL', no transparency. |
pch_cex |
A numeric value indicating **c**haracter **ex**pansion (i.e., size scaling factor) of symbols defined by 'pch'. Default to 1. |
bars_color |
A character vector of one element indicating the color for node age distribution bars. Defaults to "#80808050", which is hex for gray ("#808080") with 50% transparency. |
bars_lty |
A numeric vector or character string indicating the plotting line type for bars. See [graphics::par()] for options. Default to "solid". |
bars_lwd |
A numeric vector indicating the line width for age distribution bars. See [graphics::par()] for options. Default to 7. |
add_legend |
Default to 'TRUE', adds a legend to the left of the plot. |
legend_cex |
A numeric value indicating **c**haracter **ex**pansion (i.e., size scaling factor) of legend. Default to one half the size of the axis label, 'cex_axislabel * 0.5'. |
legend_pt_cex |
A numeric value indicating **c**haracter **ex**pansion (i.e., character size scaling factor) of legend points. Default to one half the size of the axis label, 'cex_axislabel * 0.5'. |
legend_x |
the x co-ordinate to be used to position the legend on the left side of the plot. |
legend_y |
the y co-ordinate to be used to position the legend on the left side of the plot. |
legend_box |
Default to 'TRUE', adds a box around the legend. |
legend_pch |
A numeric vector indicating the symbol to use in legend. See [graphics::par()] for options. Defaults to 20 = "bullet circle". |
legend_text |
A character vector indicating the text to use as legend. |
legend_color |
A character vector indicating the colors to use in legend. |
legend_title |
A character vector indicating the title to use in legend. |
... |
Arguments passed on to
|
Plot are margin sizes as defined by [graphics::par()$mai] and [graphics::par()$omi] are overruled within the function. To modify them you have to use the arguments 'mai1', 'mai2', 'mai3' and 'mai4', and omi1, omi2, omi3 and omi4.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.