Candlesticks run off edges with small number of candlesticks
Posted: Fri Mar 11, 2005 5:43 pm
I've run into a problem where if I'm using less than about 8 candlesticks in my graph the first and last one run off the edges of my graph and don't line up with their tick marks. This happens even when I just use the sample jfree demo code and lower the number of candles to <8. Here's what it looks like with the demo code:
Looks all ok with 10 candles:

Starts to run off the edge at 8 candles:

Is significantly off the edge at 4 candles:

Since my application uses < 5 candles this is a big problem for me that I haven't been able to work around. Any suggestions? Seems like something with CandlestickRenderer.java but I don't see what.
I'm using jfreechart-0.9.21, though it looks like CandlestickRenderer.java hasn't changed since then.
Thanks,
Jason
Looks all ok with 10 candles:

Starts to run off the edge at 8 candles:

Is significantly off the edge at 4 candles:

Since my application uses < 5 candles this is a big problem for me that I haven't been able to work around. Any suggestions? Seems like something with CandlestickRenderer.java but I don't see what.
I'm using jfreechart-0.9.21, though it looks like CandlestickRenderer.java hasn't changed since then.
Thanks,
Jason