forest_plot function

Forest plot

Forest plot

Create a forest plot using outputs from 'metafor' package

forest_plot( estimates = NULL, estimate_ci_ll = NULL, estimate_ci_ul = NULL, point_size_range = c(2, 10), error_bar_size = 1, error_bar_tip_height = 0.3, weights = NULL, diamond_x = NULL, diamond_ci_ll = NULL, diamond_ci_ul = NULL, diamond_height = 1.2, diamond_gap_height = 0.3, diamond_1_tip_at_top_y = -0.5, diamond_colors = "black", study_labels = NULL, diamond_labels = NULL, diamond_label_size = 6, diamond_label_hjust = 0, diamond_label_fontface = "bold", diamond_estimate_label_hjust = 0, diamond_estimate_label_size = 6, diamond_estimate_label_fontface = "bold", round_estimates = 2, x_axis_title = "Observed Outcome", vline_size = 1, vline_intercept = 0, vline_type = "dotted", study_label_hjust = 0, study_label_begin_x = NULL, study_label_begin_x_perc = 60, study_label_size = 6, study_label_fontface = "plain", estimate_label_begin_x = NULL, estimate_label_begin_x_perc = 25, estimate_label_hjust = 0, estimate_label_size = 6, estimate_label_fontface = "plain", x_axis_tick_marks = NULL, x_axis_tick_mark_label_size = 6, legend_position = "none", plot_margin = NULL )

Arguments

  • estimates: default = NULL
  • estimate_ci_ll: default = NULL
  • estimate_ci_ul: default = NULL
  • point_size_range: default = c(2, 10)
  • error_bar_size: default = 1
  • error_bar_tip_height: default = 0.3
  • weights: default = NULL
  • diamond_x: default = NULL
  • diamond_ci_ll: default = NULL
  • diamond_ci_ul: default = NULL
  • diamond_height: default = 1.2
  • diamond_gap_height: default = 0.3
  • diamond_1_tip_at_top_y: default = -0.5
  • diamond_colors: default = "black"
  • study_labels: default = NULL
  • diamond_labels: default = NULL
  • diamond_label_size: default = 6
  • diamond_label_hjust: default = 0
  • diamond_label_fontface: default = "bold"
  • diamond_estimate_label_hjust: default = 0
  • diamond_estimate_label_size: default = 6
  • diamond_estimate_label_fontface: default = "bold"
  • round_estimates: default = 2
  • x_axis_title: default = "Observed Outcome"
  • vline_size: default = 1
  • vline_intercept: default = 0
  • vline_type: default = "dotted"
  • study_label_hjust: default = 0
  • study_label_begin_x: default = NULL
  • study_label_begin_x_perc: default = 60
  • study_label_size: default = 6
  • study_label_fontface: default = "plain"
  • estimate_label_begin_x: default = NULL
  • estimate_label_begin_x_perc: default = 25
  • estimate_label_hjust: default = 0
  • estimate_label_size: default = 6
  • estimate_label_fontface: default = "plain"
  • x_axis_tick_marks: default = NULL
  • x_axis_tick_mark_label_size: default = 6
  • legend_position: default = "none"
  • plot_margin: default = NULL

Examples

forest_plot( estimates = c(2, 3, 4), estimate_ci_ll = c(1, 2, 3), estimate_ci_ul = c(3, 4, 6), weights = 1:3, diamond_x = 2, diamond_labels = "RE", diamond_ci_ll = 1.8, diamond_ci_ul = 2.2, estimate_label_begin_x_perc = 40, x_axis_tick_marks = seq(-2, 6, 2))