propogate_data checks each layer for a data set. If none is found it assigns a copy of the plot level data set to the layer. propogate_data avoids the side effects of ggplot2:::map_layout, which performs a similar function.
1 | propogate_data(layers, plot_data)
|
layers |
ggplot2 layer objects |
plot_data |
the global data set for a ggplot2 plot |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.