|
In order to use the CandlestickSeries, the file EJSChart_Stock.js must be included in the HTML page after the inclusion of the standard EJSChart.js file.
<head> <script type="text/javascript" src="/EJSChart/EJSChart.js"></script> <script type="text/javascript" src="/EJSChart/EJSChart_Stock.js"></script> </head>
CandlestickSeries renders its point data as vertical boxes with optional "wicks" to express open and close values.
The constructor expects an instantiated EJSC.DataHandler descendant and an optional set of object properties.
Constructor
EJSC.CandlestickSeries( EJSC.DataHandler dataHandler [, object options] )
Example
var mySeries = new EJSC.CandlestickSeries( new EJSC.ArrayDataHandler([[1,10,1,2,9],[2,20,7,10,19]]), { title: "New Candlestick Series" } );
Defining Properties and Events
CandlestickSeries properties may be set individually after the series has been created or in batch using the options parameter during instantiation.
Setting properties individually
var mySeries = new EJSC.CandlestickSeries(new EJSC.ArrayDataHandler([[1,10,1,2,9],[2,20,7,10,19]])); mySeries.lineWidth = 1; mySeries.title = "New Candlestick Series";
Setting properties in batch
var mySeries = new EJSC.CandlestickSeries( new EJSC.ArrayDataHandler([[1,10,1,2,9],[2,20,7,10,9]]), { lineWidth: 1, title: "New Candlestick Series" } );
|