Page 1 of 1

No Volume for OHLCSeries???

Posted: Sat Jun 26, 2010 10:36 am
by Bigdaddy
I am trying to use the OHLCSeriesCollection because it allows the manipulation of the XPostion, but I cannot get the volume for any given index. The problem appears to be with the OHLCSeries, because it does not have a method that allows volume to be added along with the other OHLC values. Is this an oversight or did I miss something? How do I associate volume with other OHLC values that are added to an OHLCSeries which is the only thing that can be added to an OHLCSeriesCollection?

I use code that looks something like the following:

ohlcSeries.add(regularTimePeriod, open, high, low, close); // Where is the method to add volume with these OHLC values?
...
ohlcSeriesCollection.add(ohlcSeries);
...
ohlcSeriesCollection.getVolume(series, item); // This will throw an exception, because there is no volume associated with anything in the OHLCSeries

Re: No Volume for OHLCSeries???

Posted: Sat Jun 26, 2010 10:46 am
by Bigdaddy
Nevermind. I reread the documentation for the getVolume() method under OHLCSeriesCollection where it states the volume will always be null for getVolume() or Double.NAN for getVolumeValue()? It sure would be nice if the volume could be associated with the other OHLC values for an OHLCSeries or if an OHLCDataset could be added to an OHLCSeriesCollection, because an OHLCSeriesCollection allows one to manipulate the XPosition of the data whereas the OHLCDataset does not. $0.02.