[Charts V2] Line Chart - Combining series on a tooltip

Hey there,
Playing around with the new charts component.

I have a line chart that has 2 series:

For each series, I was able to customize (a bit) the tooltip when hovering the line:


(basically adding € at the end of the value)

The data model is pretty simple, that's an array in which each row has:

  • a date
  • an amount, lets call it A
  • another amount which we call B

But when hovering the chart, I can't find out how to create a tooltip that could summarize A and B.
Tooltip will only display the series that's hovered.

My goal is to achieve something similar to this (data wise forget about UI), where the tooltip shows A and B for the same date:

I tried grouping series, played around, but did not find any workaround.

Any idea?

Thanks!
Hugo

+1 I am also trying to achieve this.

Hi there,

I haven't found a way to do this with the plotly formatting that you're using, but It looks like you can enable "Use array" for the tooltip and pass in an array of strings that you want to show for each data point. You could use Javascript to calculate the data you want to show in each string

Thanks @Tess.
I'm a bit confused by the use of the term "plotly formating" as I'm using Charts V2 — Are they also based on plotly technology?

Anyway, I'm going to try this answer Hovertemplate questions for charts V2 - #2 by Darren from @James_Tuxbury's topic.

Quick feedback tho: the "Use array" checkbox is very hard to find btw, as you first have to click on "FX" prior to see it.

Will try this out. Thanks!

Hi @H_L,

Thanks for the feedback! Yes, the new chart also uses Plotly.

Let us know how it goes :slightly_smiling_face: