How to: |
The majorGrid properties control the visibility and format of major grid lines and tick marks.
"axisname": { "majorGrid": { "visible": boolean, "aboveRisers": boolean, "lineStyle": { "width": number, "color": "string", "dash": "string" }, "ticks": { "length": number, "visible": boolean, "style": "string", "lineStyle": { "width": number, "color": "string"} } } }
where;
Can be:
Defines the major grid line properties.
Controls the visibility of the major grid lines. The default depends on the type of chart being generated. Valid values are:
Controls whether the grid lines are drawn in front of or behind the risers. Valid values are:
Defines the style of the major grid lines.
Is a number that defines the width of major grid lines in pixels. The default value is 1.
Is a string that defines the color of major grid lines using a color name or numeric specification string. The default value is "rgba(255, 255, 255, 0.3)".
For information about defining colors, see Colors and Gradients.
Is a string that defines the dash style. The default value is "" (which generates a solid line). Use a string of numbers that defines the width of a dash followed by the width of the gap between dashes (for example, dash: "1 1" draws a dotted line).
Defines the tick marks for the major grid lines.
Is a number that defines the length of tick marks in pixels. The default value is 5.
Controls the visibility of tick marks. Valid values are
Is a string that defines the tick mark style. The default depends on the type of chart being generated. Valid values are:
Defines the line style of the major grid line tick marks.
Is a number that defines the width of the tick marks in pixels. The default value is 1.
Is a string that defines the color of tick marks using a color name or numeric specification string. The default value is "black".
The following request makes the major grid lines visible, 4 pixels wide, in front of the risers, and tan. The tick mark style is 'span', so they are both outside and inside the grid lines:
GRAPH FILE WF_RETAIL_LITE
SUM COGS_US
BY MODEL
WHERE PRODUCT_CATEGORY EQ 'Computers'
ON GRAPH PCHOLD FORMAT JSCHART
ON GRAPH SET LOOKGRAPH VLINE
ON GRAPH SET STYLE *
*GRAPH_JS
"border": {"width": 2, "color": "teal"},
"blaProperties": {"lineConnection": "curved"},
"yaxis": {
"title": {"visible": true},
"majorGrid": {
"visible": true,
"aboveRisers": true,
"lineStyle": {"width": 4, "color": "tan"},
"ticks": {"style": "span"}
}}
*END
ENDSTYLE
END
The output is:
The following request formats the x-axis and y-axis major grid lines in a bubble chart:
GRAPH FILE WF_RETAIL_LITE SUM COGS_US REVENUE_US DISCOUNT_US BY PRODUCT_CATEGORY ON GRAPH PCHOLD FORMAT JSCHART ON GRAPH SET LOOKGRAPH BUBBLE ON GRAPH SET STYLE * *GRAPH_JS "series": [{"series": "all", "marker": {"shape": "circle"}}], "xaxis": { "title": {"visible": true}, "majorGrid": {"lineStyle": { "width": 2, "color": "brown", "dash": "2 2"}}}, "yaxis": { "title": {"visible": true}, "majorGrid": {"lineStyle": { "width": 2, "color": "tan", "dash": "4 4"}}} *END ENDSTYLE END
The output is:
The following request generates a polar chart in which the y-axis major grid lines are tan and the x-axis major grid lines are white:
GRAPH FILE WF_RETAIL_LITE SUM DAYSDELAYED QUANTITY_SOLD ACROSS TIME_MTH ON GRAPH PCHOLD FORMAT JSCHART ON GRAPH SET LOOKGRAPH POLAR ON GRAPH SET STYLE * INCLUDE=IBFS:/FILE/IBI_HTML_DIR/javaassist/intl/EN/ENIADefault_combine.sty,$ *GRAPH_JS "polarProperties": { "straightGridLines": false, "extrudeAxisLabels": false}, "xaxis": { "title": {"visible": true}, "majorGrid": { "aboveRisers": false, "lineStyle": {"width": 2, "color": "white"}}}, "yaxis": { "title": {"visible": true}, "majorGrid": { "aboveRisers": false, "lineStyle": {"width": 2, "color": "tan"}}} *END ENDSTYLE END
The output is:
WebFOCUS | |
Feedback |