nycflights13 data — dm_nycflights13" />

Creates an example dm object from the tables in nycflights13, along with the references. See nycflights13::flights for a description of the data. As described in nycflights13::planes, the relationship between the flights table and the planes tables is "weak", it does not satisfy data integrity constraints.

dm_nycflights13(cycle = FALSE, color = TRUE, subset = TRUE)



Boolean. If FALSE (default), only one foreign key relation (from flights$origin to airports$faa) between the flights table and the airports table is established. If TRUE, a dm object with a double reference between those tables will be produced.


Boolean, if TRUE (default), the resulting dm object will have colors assigned to different tables for visualization with dm_draw().


Boolean, if TRUE (default), the flights table is reduced to flights with column day equal to 10.


A dm object consisting of nycflights13 tables, complete with primary and foreign keys and optionally colored.


if (rlang::is_installed("nycflights13") && rlang::is_installed("DiagrammeR")) (if (getRversion() >= "3.4") withAutoprint else force)({ # examplesIf dm_nycflights13() %>% dm_draw() }) # examplesIf
#> > dm_nycflights13() %>% dm_draw()