I would like to get a text on the middle of a line.
Until now, when I create a line, that put the text only on the start or the end point of the line. For more lisibility, I would like to put the text on the middle of the line.
How to do it plz ?
Plotting text with your data (mode=‘text’) only allows the data to appear at your data points. To add text to your graph between your data points you could add an annotation: https://plot.ly/python/text-and-annotations/#simple-annotation
Thanks for your answer. Indeed that work great ! But is there any possibility to get an hover on the middle of the line instead of a static text ?
And is there a way go get an scattergl plot with gl annotations ?
Unfortunately it is not possible to get hover in the middle of the line.
You may be able to hack around this by adding a transparent point w/ the hover information you wish to represent in the middle of your line, but as far as plotting a line goes, we don’t interpolate points to display hover information.