3

I have a problem with finding a way to highlight a specific range and possibly label it at the top in the Rickshaw charts as on this example

enter image description here

Is there a way of achieving such a highlight in Rickshaw? It could be very useful for annotating a period rather than point in time.

Do you have any ideas how can I achieve that?

Charles
  • 50,943
  • 13
  • 104
  • 142
Marcin
  • 5,469
  • 15
  • 55
  • 69
  • You could add a rectangle covering the region you want to highlight manually. – Lars Kotthoff May 04 '14 at 11:41
  • How should I know the x and y of the point it should start at? – Marcin May 04 '14 at 16:03
  • Hmm, it looks like you can't get access to the scales that rickshaw uses unfortunately, so this won't work. If start/end correspond to a specific data point though, you could get the DOM element that corresponds to it though and use its coordinates. – Lars Kotthoff May 04 '14 at 16:15
  • You can use graph.x(value) to get the position for any date. This will return the left offset from the graph 0 point. – Marco Gabriel Godoy Lema Jun 09 '14 at 17:42
  • Did you figure this out? I am comparing Rickshaw v/s Dygraph and dygraph seems to have a highlight feature that Rickshaw doesn't explicitly. Reference - http://dygraphs.com/gallery/#g/highlighted-region – Pratik Mandrekar Nov 15 '14 at 14:45

0 Answers0