# Example 1: Create an overlay with shape position "top-left"
overlay_style <- create_overlay_style(
font_color = 'DarkSlateGray',
font_size = 23,
fill_color = 'MistyRose',
stroke_color = 'Red'
)
overlay <- create_overlay(
"my-shape-id",
"My Overlay Label",
style = overlay_style,
position = overlay_shape_position[1]
)
# Example 2: Create an overlay with edge position "end"
overlay_style <- create_overlay_style(
font_color = 'DarkSlateGray',
font_size = 23,
fill_color = 'MistyRose',
stroke_color = 'Red'
)
overlay <- create_overlay(
"my-edge-id",
"My Overlay Label",
style = overlay_style,
position = overlay_edge_position[2]
)
Run the code above in your browser using DataLab