View source: R/add_unused_levels.R
add_unused_levels | R Documentation |
Add a row for each unused factor level to ensure plotly displays all levels in the legend.
add_unused_levels(data, var)
data |
A tibble, dataframe or sf object. Required input. |
var |
A variable of class factor. |
A tibble, dataframe or sf object. Required input.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.