Function Reference
Complete reference for all tabviz functions, organized by category.
Core Functions
| Function | Description |
|---|---|
tabviz() |
Main entry point — Create interactive tables with any columns |
forest_plot() |
Convenience wrapper for quick forest plots |
save_plot() |
Export to SVG, PNG, or PDF |
# Create a table with a forest plot column
tabviz(data, label = "study", columns = list(
viz_forest(point = "hr", lower = "lo", upper = "hi"),
col_numeric("hr", "HR"),
col_pvalue("pval")
))
# Quick forest plot (auto-creates viz_forest column)
forest_plot(data, point = "hr", lower = "lo", upper = "hi", label = "study")Column Types
Basic Columns
| Function | Description |
|---|---|
col_text() |
Text column |
col_numeric() |
Numeric column with formatting |
col_n() |
Sample size column |
col_percent() |
Percentage column |
col_interval() |
Confidence interval display |
col_events() |
Events/N format |
col_pvalue() |
P-value with formatting |
Visualization Columns
| Function | Description |
|---|---|
viz_forest() |
Forest plot column with intervals |
viz_bar() |
Horizontal bar chart with axis |
viz_boxplot() |
Box-and-whisker plots |
viz_violin() |
Violin/density plots |
col_bar() |
Simple inline bar |
col_sparkline() |
Inline sparkline |
col_badge() |
Colored status badges |
col_stars() |
Star ratings |
col_icon() |
Icon/emoji column |
col_img() |
Inline images |
col_reference() |
Truncated references with links |
col_range() |
Min-max range display |
Effect Specifications
| Function | Description |
|---|---|
effect_forest() |
Define effect for multi-effect forest plots |
effect_bar() |
Define bar in viz_bar() |
effect_boxplot() |
Define boxplot in viz_boxplot() |
effect_violin() |
Define violin in viz_violin() |
Column Groups
| Function | Description |
|---|---|
col_group() |
Group columns under header |
Styling Functions
Apply styling using the fluent API with pipes:
| Function | Description |
|---|---|
set_row_style() |
Row-level styling (bold, italic, color, type, indent) |
set_marker_style() |
Style interval markers (color, shape, opacity, size) |
set_column_style() |
Per-cell styling for specific columns |
set_theme() |
Apply a theme by name or object |
NoteConstructor Arguments vs Fluent API
Every styling function has equivalent direct arguments in tabviz():
# These produce identical results:
tabviz(data, ..., row_bold = "is_summary", marker_color = "dir_color")
tabviz(data, ...) |>
set_row_style(bold = "is_summary") |>
set_marker_style(color = "dir_color")Use direct arguments when configuration is known upfront. Use the fluent API when styling depends on computation.
Themes
Preset Themes
| Function | Description |
|---|---|
web_theme_default() |
Clean, modern default theme |
web_theme_jama() |
JAMA journal style |
web_theme_lancet() |
Lancet journal style |
web_theme_nature() |
Nature journal style |
web_theme_cochrane() |
Cochrane Collaboration style |
web_theme_modern() |
Contemporary UI |
web_theme_presentation() |
Large fonts for slides |
web_theme_dark() |
Dark mode |
web_theme_minimal() |
Minimal B&W |
Theme Modifiers
| Function | Description |
|---|---|
set_colors() |
Customize colors |
set_typography() |
Customize fonts |
set_spacing() |
Customize spacing |
set_shapes() |
Customize shapes |
set_axis() |
Customize axis |
set_layout() |
Customize layout |
set_group_headers() |
Customize group header hierarchy |
Annotations
| Function | Description |
|---|---|
refline() |
Add reference line |
forest_annotation() |
Custom annotation |
Interaction Settings
| Function | Description |
|---|---|
web_interaction() |
Full control over interaction settings |
web_interaction_minimal() |
Hover only preset |
web_interaction_publication() |
Static/print preset |
Shiny Integration
Standard Tables
| Function | Description |
|---|---|
forestOutput() |
Shiny UI output |
renderForest() |
Shiny server render |
forestProxy() |
Create update proxy |
forest_update_data() |
Update table data |
forest_sort() |
Sort by column |
forest_filter() |
Filter rows |
forest_clear_filter() |
Clear filters |
forest_toggle_subgroup() |
Toggle group collapse |
Split Tables
| Function | Description |
|---|---|
splitForestOutput() |
Shiny UI output for split view |
renderSplitForest() |
Shiny server render for split view |
splitForestProxy() |
Create split view proxy |
split_table_select() |
Select sub-table programmatically |
Advanced
| Function | Description |
|---|---|
split_table() |
Split data into multiple sub-tables |
web_group() |
Define row group explicitly |