HighLowChartOptions
New in version 5.0
HighLowChartOptions ( bullishColor ; bullishColorVariant ; highTickMarkAttributes ; lowTickMarkAttributes ; closeTickMarkAttributes ; openTickMarkAttributes )
Argument | Type | Range | Default | Note |
---|---|---|---|---|
bullishColor | rgba | 0..255 | none | |
bullishColorVariant | int | -1..128 | solid | |
highTickMarkAttributes | num[] | 0 | xmCHART 5.0.5 or higher required | |
lowTickMarkAttributes | num[] | 0 | xmCHART 5.0.5 or higher required | |
closeTickMarkAttributes | num[] | 0 | xmCHART 5.0.5 or higher required | |
openTickMarkAttributes | num[] | 0 | xmCHART 5.0.5 or higher required |
Examples
Description
The color of the high-low marker for a higher closing (bullish) can be varied by using the arguments bullishColor and bullishColorVariant. Please note that the
| HIGH_LOW_CHART_OPTIONS_01 |
1 | OpenDrawing(250;150) |
2 | ChartData(118 122 118 116 118 121 123; /* High-values. */ |
3 | 102 105 104 104 109 111 113; /* Low-values. */ |
4 | 104 119 118 108 118 118 113; /* Close-values. */ |
5 | 113 121 114 112 115 121 121) /* Open-values. */ |
6 | HighLowChart(;on;highLowCloseOpen;0;;0;;;right;;left) |
7 | HighLowChartOptions(green) /* After HighLowChart() */ |
8 | /* Set up styles. */ |
9 | |
10 | /* Set up axes. */ |
11 | |
12 | AxisMajorTicks(all;0) |
13 | /* Set up grid. */ |
14 | MajorGridLineWidths(x;y;0.25) |
15 | MajorGridLineWidths(y;x;0) |
16 |
| HIGH_LOW_CHART_OPTIONS_02 |
1 | OpenDrawing(250;150) |
2 | ChartData(2024-11-30 2024-12-01 2024-12-04 2024-12-06 2024-12-07 2024-12-08; |
3 | 118 122 118 126 126 121 123; /* High-values. */ |
4 | 102 105 104 104 106 111 113; /* Low-values. */ |
5 | 104 119 118 108 122 118 113; /* Close-values. */ |
6 | 113 121 114 112 112 121 121) /* Open-values. */ |
7 | HighLowChart2D(;highLowCloseOpen;0;;0;;;right;;left) |
8 | HighLowChartOptions(red) /* After HighLowChart() */ |
9 | /* Set up styles. */ |
10 | |
11 | /* Set up axes. */ |
12 | ScalingOptions(y;on) /* y-scale top to bottom. */ |
13 | |
14 | AxisMajorTicks(all;0) |
15 | AxisMajorTickLabelStyle(x;;;;;;-90) |
16 | AxisMajorTickLabelOptions(x;;;3) |
17 | /* Set up grid. */ |
18 | MajorGridLineWidths(x;y;0.25) |
19 | MajorGridLineWidths(y;x;0) |
20 |
The arguments highTickMarkAttributes, lowTickMarkAttributes, closeTickMarkAttributes and openTickMarkAttributes make it possible to create range plots. The tick mark attributes can have up to five values:
[1]: Marker thickness.
[2]: Marker color (only color names and hexColor codes are allowed - not allowed is a list of rgb color components, e.g. 255 0 0)
[3]: Label position constant. (name or integer between 0 and 9)
[4]: Horizontal label offset (a positive offset moves the label away from the bar)
[5]: Vertical label offset (a positive offset moves the label away from the bar)
| HIGH_LOW_CHART_OPTIONS_03 |
1 | OpenDrawing(250;150) |
2 | |
3 | ChartData(1.20 1.22; /* High-values. */ |
4 | 1.00 1.05; /* Low-values. */ |
5 | 1.17 1.19) /* Close-values. */ |
6 | |
7 | 100;center; /* highTickMarkLenght ; highTickMarkAlignment */ |
8 | 100;center; /* lowTickMarkLenght ; lowTickMarkAlignment */ |
9 | 100;center) /* closeTickMarkLenght ; closeTickMarkAlignment */ |
10 | HighLowChartOptions(;; |
11 | 1.0 gray bottomCenter 0 10; /* "High" value marker: [thickness color position hOffset vOffset] */ |
12 | 1.0 gray bottomCenter 0 10; /* "Low" value marker: [thickness color position hOffset vOffset] */ |
13 | 1.5 red topCenter 0 11) /* "Close" value marker: [thickness color position hOffset vOffset] */ |
14 | |
15 | /* Set up styles. */ |
16 | LineStyle(1;;20;#f0f0f0) |
17 | LabelTexts(all;"|f2|%") |
18 | LabelStyle(all;Verdana;8.5;plain;#555) |
19 | |
20 | /* Set up axes. */ |
21 | AxisOptions(x;none) /* Hide x-axis. */ |
22 | |
23 | AxisMajorTicks(y;0) |
24 | AxisMajorTickLabelTexts(y;"A";"B") |
25 | AxisMajorTickLabelOptions(y;;-10) |
26 | ScalingOptions(y;on) /* Reverse y-axis. */ |
27 | GridLocation(all;none) /* Hide grid. */ |
28 | |
29 |
| HIGH_LOW_CHART_OPTIONS_04 |
1 | OpenDrawing(330;270) |
2 | |
3 | ChartData(1.20 1.22 1.23; /* High-values. */ |
4 | 1.05 1.01 0.98; /* Low-values. */ |
5 | 1.17 1.19 1.18; /* Close-values. */ |
6 | 1.13 1.10 1.13) /* Open-values. */ |
7 | |
8 | 100;center; /* highTickMarkLenght ; highTickMarkAlignment */ |
9 | 100;center; /* lowTickMarkLenght ; lowTickMarkAlignment */ |
10 | 100;center; /* closeTickMarkLenght ; closeTickMarkAlignment */ |
11 | 100;center) /* openTickMarkLenght ; openTickMarkAlignment */ |
12 | HighLowChartOptions(;; |
13 | 0.0 none topCenter 0 1; /* No high value marker, only the position of the label is used. */ |
14 | 0.0 none bottomCenter 0 1; /* No low value marker, only the position of the label is used. */ |
15 | 3.0 yellow centerLeft 11 0; /* "Close" value marker: [thickness color position hOffset vOffset] */ |
16 | 2.0 #0ff centerRight 11 0) /* "Open" value marker: [thickness color position hOffset vOffset] */ |
17 | |
18 | /* Set up styles. */ |
19 | |
20 | LabelTexts(all;"|f2|%") |
21 | LabelStyle(all;Verdana;8.5;plain;#555) |
22 | ShadowStyle(all;2 2 3;lightGray) |
23 | |
24 | /* Set up axes. */ |
25 | |
26 | AxisMajorTicks(all;0) |
27 | AxisMajorTickLabelTexts(x;"TEST A";"TEST B";"TEST C") |
28 | AxisMajorTickLabelStyle(x;Verdana;10;plain;#555;center;0;50;40) |
29 | AxisMajorTickLabelOptions(x;;;8) |
30 | AxisMajorTickLabelStyle(y;Verdana;10;plain;#555) |
31 | AxisOptions(y;;2) /* Mirror y-axis. */ |
32 | |
33 | /* Set up grid. */ |
34 | MajorGridLineWidths(y;x;0) /* Hide vertical grid lines. */ |
35 | MajorGridLineWidths(x;y;0.25) |
36 | MajorGridLineColors(x;y;#ddd) |
37 | |
38 |