User Guide
The following group of functions is used to create custom indicators.
void SetDigits(int digits)
Setting the indicator precision. Used for displaying the numbers in a vertical axis.
void SetIndexCount(int count)
Setting the number of buffers for indicator values.
bool SetIndexBuffer(int index,double[]@ buffer)
Setting the buffer that is holding values of an indicator. The parameters are the buffer number and the reference to an array with the reverse indexing from the global script variables.
void SetIndexDrawStart(int index,int pos)
Setting the position from where the rendering of the indicator buffer starts. The parameters are the buffer number and the starting position.
void SetIndexEmptyValue(int index,double value)
Setting a void value for the indicator buffer. Void values are not engaged in the rendering of an indicator.
void SetIndexShift(int index,int shift)
Setting the shift of the indicator buffer rendering. The parameters are the buffer number and the shift.
void SetIndexStyle(int index,int type,int style,int width,color clr)
Setting the graphical properties of the indicator buffer rendering.
Parameters:
- index - buffer number
- type - indicator line drawing type
- style - line style
- width - line thickness (permissible values are from 1 to 5)
- clr - color. One of color constants or a color in RGB format type such as 0xAABBCC, where AA-red, BB-green and CC-blue components
Properties of the Indicator object
- int Calculated - number of counted bars of an indicator
Rendering a chart in a separate window
To display the chart in a separate window, the following preprocessor directive should be used:
#set_indicator_separateExamples of indicators usage