forest_plot_1_to_many | R Documentation |
Plot results from an analysis of multiple exposures against a single outcome or a single exposure against multiple outcomes.
Plots effect estimates and 95 percent confidence intervals.
The ordering of results in the plot is determined by the order supplied by the user.
Users may find sort_1_to_many()
helpful for sorting their results prior to using the 1-to-many forest plot. The plot function works best for 50 results and is not designed to handle more than 100 results.
forest_plot_1_to_many(
mr_res = "mr_res",
b = "b",
se = "se",
TraitM = "outcome",
col1_width = 1,
col1_title = "",
exponentiate = FALSE,
trans = "identity",
ao_slc = TRUE,
lo = NULL,
up = NULL,
by = NULL,
xlab = "Effect (95% confidence interval)",
addcols = NULL,
addcol_widths = NULL,
addcol_titles = "",
subheading_size = 6,
shape_points = 15,
colour_scheme = "black",
col_text_size = 5,
weight = NULL
)
mr_res |
Data frame of results supplied by the user. The default is |
b |
Name of the column specifying the effect of the exposure on the outcome. The default is |
se |
Name of the column specifying the standard error for b. The default is |
TraitM |
The column specifying the names of the traits. Corresponds to 'many' in the 1-to-many forest plot. The default is |
col1_width |
Width of Y axis label for the column specified by the TraitM argument. The default is |
col1_title |
Title for the column specified by the TraitM argument. The default is |
exponentiate |
Convert log odds ratios to odds ratios? Default is |
trans |
Specify x-axis scale. e.g. "identity", "log2", etc. If set to "identity" an additive scale is used. If set to log2 the x-axis is plotted on a multiplicative / doubling scale (preferable when plotting odds ratios). Default is |
ao_slc |
Logical; retrieve trait subcategory information using available_outcomes(). Default is |
lo |
Lower limit of X axis to plot. |
up |
upper limit of X axis to plot. |
by |
Name of the grouping variable to stratify results on. Default is |
xlab |
X-axis label, default is |
addcols |
Name of additional columns to plot. Character vector. The default is |
addcol_widths |
Widths of Y axis labels for additional columns specified by the addcols argument. Numeric vector. The default is |
addcol_titles |
Titles of additional columns specified by the addcols argument. Character vector. The default is |
subheading_size |
text size for the subheadings specified in by argument. The default is |
shape_points |
the shape of the data points to pass to |
colour_scheme |
the general colour scheme for the plot. Default is to make all text and data points |
col_text_size |
The default is |
weight |
The default is |
grid plot object
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.