as_svg_anim | R Documentation |
Idea borrowed from pointblank
as_svg_anim(
x,
width = 1200,
height = 900,
duration = 1,
playback = c("infinite", "click"),
font_size = NULL,
style = list(),
svg_id = NULL,
browsable = FALSE
)
x |
list of emphatic objects |
width , height |
viewBox dimensions for SVG |
duration |
frame duration in seconds. May be a single value used for all frames, or a vector of values (one duration value for each frame). Can be fractions of a second. |
playback |
'click', 'infinite' |
font_size |
CSS font-size. Default: NULL means to not adjust font size.
Otherwise, use valid CSS |
style |
html tag styling to apply to the |
svg_id |
ID to use for the SVG tag. Default: NULL means to create a random ID |
browsable |
Should the SVG be rendered to the RStudio Viewer pane when when printed (instead of console output)? Default: FALSE |
Character string containing an animated SVG representation displaying all elements sequentially
list(
hl_diff('hello', 'there'),
hl_diff('goodbye', 'good boy')
) |>
as_svg_anim() |>
cat()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.