4646
4747# By default, all selections are transient, meaning prior selections are
4848# removed from the selection set before new selections are added. To prevent
49- # prior selections from being removed, simply set the persistent argument to
50- # `TRUE`.
51- highlight(p , on = " plotly_hover" , persistent = TRUE )
49+ # prior selections from being removed, hold down the shift key while triggering
50+ # the event
51+ highlight(p , on = " plotly_hover" )
5252
5353# Sometimes its useful to compare two or more different selection sets.
5454# For example, how do patients with a high response on visit 1 compare to those
@@ -57,10 +57,10 @@ highlight(p, on = "plotly_hover", persistent = TRUE)
5757# a colourpicker htmlwidget (@colourpicker) will appear just above the plotly
5858# visualization. At any given time, the value of this widget controls the
5959# color of new selection(s).
60- highlight(p , on = " plotly_hover" , persistent = TRUE , dynamic = TRUE )
60+ highlight(p , on = " plotly_hover" , dynamic = TRUE )
6161
6262# By default, the colourpicker widget uses colors from the "Set1"
6363# colour brewer palette (@RColorBrewer), but any set of valid R colors can
6464# be supplied to the color argument.
6565colors <- RColorBrewer :: brewer.pal(4 , " Dark2" )
66- highlight(p , on = " plotly_hover" , color = colors , dynamic = TRUE , persistent = TRUE )
66+ highlight(p , on = " plotly_hover" , color = colors , dynamic = TRUE )
0 commit comments