Binds events to chart interactions.

e_on(e, query, handler, event = "click")

e_off(e, query, handler, event = "click")

Arguments

e

An echarts4r object as returned by e_charts or a proxy as returned by echarts4rProxy.

query

Condistion that triggers the handler

handler

JavaSscript handler, passed to JS.

event

Event that triggers the handler.

See also

Examples

cars |> e_charts(speed) |> e_scatter(dist) |> e_on( list(seriesName = "dist"), "function(){alert('Serie clicked')}" )