Generate a flowchart of the history of the dataframe(s), with all the tracked data pipeline as stages in the flowchart. Multiple dataframes can be plotted together in which case an attempt is made to determine which parts are common.

  filename = NULL,
  size = std_size$half,
  maxWidth = size$width,
  maxHeight = size$height,
  formats = c("dot", "png", "pdf", "svg"),
  defaultToHTML = TRUE,
  landscape = size$rot != 0,



the tracked dataframe(s) either as a single dataframe or as a list of dataframes.


a file name which will be where the formatted flowcharts are saved. If no extension is specified the output formats are determined by the formats parameter.


a named list with 3 elements, length and width in inches and rotation. A predefined set of standard sizes are available in the std_size object.


a width (on the paper) in inches if size is not defined


a height (on the paper) in inches if size is not defined


some of pdf,dot,svg,png,ps


if the correct output format is not easy to determine from the context, default providing HTML (TRUE) or to embedding the PNG (FALSE)


rotate the output by 270 degrees into a landscape format. maxWidth and maxHeight still apply and refer to the paper width to fit the flowchart into after rotation. (you might need to flip width and height)


other parameters passed onto either p_get_as_dot(), notable ones are fill (background colour e.g. lightgrey), fontsize (in points), colour (font colour)


the nature of the flowchart output depends on the context in which the function is called. It will be some form of browse-able html output if called from an interactive session or a PNG/PDF link if in knitr and knitting latex or word type outputs, if file name is specified the output will also be saved at the given location.



tmp = iris %>% track() %>% comment(.tag = "step1") %>% filter(Species!="versicolor")
tmp %>% group_by(Species) %>% comment(.tag="step2") %>% flowchart()