Uses a callback function within chartjs. Reference elements using template literal notation e.g. 'x value: $x, y value: $y'. See vignette('tooltips-and-interaction-modes', package = 'chartjs4r')

cjs_tooltip(
  p,
  label,
  title,
  beforeTitle,
  afterTitle,
  footer,
  beforeFooter,
  afterFooter
)

Arguments

p

chartjs object

label

=

title

= 'title_text'

beforeTitle

= 'beforeTitle_text'

afterTitle

= 'afterTitle_text'

footer

= 'footer_text',

beforeFooter

= 'beforeFooter_text'

afterFooter

= 'afterFooter_text'

Value

An object of class htmlwidget