fc_draw {flowchart} | R Documentation |
fc_draw
Description
This function allows to draw the flowchart from a fc object.
Usage
fc_draw(
object,
arrow_angle = 30,
arrow_length = grid::unit(0.1, "inches"),
arrow_ends = "last",
arrow_type = "closed"
)
Arguments
object |
fc object that we want to draw. |
arrow_angle |
The angle of the arrow head in degrees, as in 'arrow'. |
arrow_length |
A unit specifying the length of the arrow head (from tip to base), as in 'arrow'. |
arrow_ends |
One of "last", "first", or "both", indicating which ends of the line to draw arrow heads, as in 'arrow'. |
arrow_type |
One of "open" or "closed" indicating whether the arrow head should be a closed triangle, as in 'arrow'. |
Value
Invisibly returns the same object that has been given to the function, with the given arguments to draw the flowchart stored in the attributes.
Examples
clinic_patient |>
as_fc(label = "Available patients") |>
fc_filter(age >= 18 & consent == "Yes", label = "Patients included", show_exc = TRUE) |>
fc_split(group) |>
fc_filter(n_visits == 2, label = "Two visits available", show_exc = TRUE) |>
fc_split(marker_alt, label = c("Marker not alterated", "Marker alterated")) |>
fc_draw()
[Package flowchart version 0.3.0 Index]