Scaling

Scaling ( axisIndex ;​ type ;​ minValue ;​ maxValue ;​ numOfMajorIntervals ;​ numOfMinorIntervals ;​ logBaseValue ;​ useEquidistantLogScaling )

Argument Type Range Default Note
axisIndex int 0..10000 all
type int 1..3 linear
minValue num -inf..+inf (autom.)
maxValue num -inf..+inf (autom.)
numOfMajorIntervals int -18..1000 (autom.)
numOfMinorIntervals int -18..1000 1
logBaseValue num 1.0001..inf 10
useEquidistantLogScaling int 0..1 off
Examples

Scaling(x;​linear;​0)

Scaling(x;​linear;​-100;​100;​10)

Scaling(x;​linear;​;​;​year;​month)

Scaling(y;​log;​;​;​;​;​2;​on)

Description

The type of scaling as well as the number of subdivisions and the scaling range can be defined by using the function Scaling(). If no scaling function is used, a suitable linear scaling is automatically computed. The 2nd argument type makes it possible to choose between linear (type = linear), percent (type = percent) and logarithmic scaling (type = log). If no type is defined, then linear scaling is used.

SCALING_01
1

OpenDrawing(250;​150)

2

ChartData(16 18 15 17 13 8)

3

LineChart(shadow+symbol+label;​on)

4

/* Set up styles. */

5

LineStyle(1;​poly;​1.5;​darkRed)

6

SymbolStyle(1;​circle;​17;​1.25;​darkRed;​;​white)

7

LabelStyle(1;​Verdana;​9)

8

LabelOptions(1;​centerCenter;​;​-1)

9

ShadowStyle(1;​2 2 3)

10

/* Set up axes. */

11

Scaling(y;​linear) /* Identical to automatic scaling. */

12

AxisLine(all;​0)

13

AxisMajorTicks(x;​5;​0.25;​#333;​;​out)

14

AxisMajorTicks(y;​0)

15

/* Set up grid. */

16

MajorGridLineWidths(x;​y;​0.25)

17

MajorGridLineWidths(y;​x;​0)

18

CloseDrawing()

SCALING_01
SCALING_02
1

OpenDrawing(250;​150)

2

ChartData(16 18 15 17 13 8)

3

LineChart(shadow+symbol+label;​on)

4

/* Set up styles. */

5

LineStyle(1;​poly;​1.5;​darkRed)

6

SymbolStyle(1;​circle;​17;​1.25;​darkRed;​;​white)

7

LabelStyle(1;​Verdana;​9)

8

LabelOptions(1;​centerCenter;​;​-1)

9

ShadowStyle(1;​2 2 3)

10

/* Set up axes. */

11

Scaling(y;​percent)

12

AxisLine(all;​0)

13

AxisMajorTicks(x;​5;​0.25;​#333;​;​out)

14

AxisMajorTicks(y;​0)

15

/* Set up grid. */

16

MajorGridLineWidths(x;​y;​0.25)

17

MajorGridLineWidths(y;​x;​0)

18

CloseDrawing()

SCALING_02
SCALING_03
1

OpenDrawing(250;​150)

2

ChartData(16 18 15 17 13 8)

3

LineChart(shadow+symbol+label;​on)

4

/* Set up styles. */

5

LineStyle(1;​poly;​1.5;​darkRed)

6

SymbolStyle(1;​circle;​17;​1.25;​darkRed;​;​white)

7

LabelStyle(1;​Verdana;​9)

8

LabelOptions(1;​centerCenter;​;​-1)

9

ShadowStyle(1;​2 2 3)

10

/* Set up axes. */

11

Scaling(y;​log)

12

AxisLine(all;​0)

13

AxisMajorTicks(x;​5;​0.25;​#333;​;​out)

14

AxisMajorTicks(y;​0)

15

/* Set up grid. */

16

MajorGridLineWidths(x;​y;​0.25)

17

MajorGridLineWidths(y;​x;​0)

18

CloseDrawing()

SCALING_03

By using the 3rd and 4th argument, a minimum and maximum scaling value can be defined. Dates and/or times can also be used as the minimum and maximum value (time axis). If the minimum or maximum value is not defined, a suitable value is automatically sought. The number of major and minor intervals can be controlled by using the 5th and 6th argument. The number of minor intervals applies to the number of intervals within a major interval, e.g. if the major intervals are to be subdivided into 5 minor intervals, numOfMinorIntervals =​ 5 should be set; if no minor tick marks are to be used, numOfMinorIntervals =​ 1 (default) should be set. If no major interval is defined, the scaling is subdivided into 4 major intervals as the default.

SCALING_04
1

OpenDrawing(250;​150)

2

ChartData(16 18 25 17 13 8)

3

LineChart(shadow+symbol+label;​on)

4

/* Set up styles. */

5

LineStyle(1;​poly;​1.5;​darkRed)

6

SymbolStyle(1;​circle;​17;​1.25;​darkRed;​;​white)

7

LabelStyle(1;​Verdana;​9)

8

LabelOptions(1;​centerCenter;​;​-1)

9

ShadowStyle(1;​2 2 3)

10

/* Set up axes. */

11

Scaling(y;​linear;​0;​30;​3;​5) /* 3 major and 5 minor intervals. */

12

AxisLine(all;​0)

13

AxisMajorTicks(x;​5;​0.5;​#333;​;​out)

14

AxisMajorTicks(y;​0)

15

AxisMinorTicks(y;​0)

16

/* Set up grid. */

17

MajorGridLineWidths(y;​x;​0)

18

MajorGridLineWidths(x;​y;​0.5)

19

MinorGridLineWidths(x;​y;​0.5)

20

CloseDrawing()

SCALING_04
SCALING_05
1

OpenDrawing(250;​150)

2

ChartData(16 18 15 17 13 8)

3

LineChart(shadow+symbol+label;​on)

4

/* Set up styles. */

5

LineStyle(1;​poly;​1.5;​darkRed)

6

SymbolStyle(1;​circle;​17;​1.25;​darkRed;​;​white)

7

LabelStyle(1;​Verdana;​9)

8

LabelOptions(1;​centerCenter;​;​-1)

9

ShadowStyle(1;​2 2 3)

10

/* Set up axes. */

11

Scaling(y;​percent;​-25;​125;​6)

12

AxisLine(all;​0)

13

AxisMajorTicks(x;​5;​0.25;​#333;​;​out)

14

AxisMajorTicks(y;​0)

15

/* Set up grid. */

16

MajorGridLineWidths(x;​y;​0.25)

17

MajorGridLineWidths(y;​x;​0)

18

CloseDrawing()

SCALING_05
SCALING_06
1

OpenDrawing(250;​150)

2

ChartData(16 18 15 17 13 8)

3

LineChart(shadow+symbol+label;​on)

4

/* Set up styles. */

5

LineStyle(1;​poly;​1.5;​darkRed)

6

SymbolStyle(1;​circle;​17;​1.25;​darkRed;​;​white)

7

LabelStyle(1;​Verdana;​9)

8

LabelOptions(1;​centerCenter;​;​-1)

9

ShadowStyle(1;​2 2 3)

10

/* Set up axes. */

11

Scaling(y;​log;​5;​20;​3;​5) /* 3 major and 5 minor intervals. */

12

AxisLine(all;​0)

13

AxisMajorTicks(x;​5;​0.25;​#333;​;​out)

14

AxisMajorTicks(y;​0)

15

AxisMinorTicks(y;​0)

16

/* Set up grid. */

17

MajorGridLineWidths(y;​x;​0)

18

MajorGridLineWidths(x;​y;​0.5)

19

MinorGridLineWidths(x;​y;​0.5)

20

CloseDrawing()

SCALING_06
SCALING_07
1

OpenDrawing(160;​160)

2

ChartData(17 24 15 17 13)

3

RadarChart()

4

RadarChartOptions(1;​poly) /* After RadarChart() */

5

/* Set up styles. */

6

FillStyle(1;​#4682b420)

7

BorderStyle(1;​poly;​1.5;​#4682b4)

8

/* Set up axes. */

9

Scaling(all;​linear;​0;​30;​3)

10

ScalingOptions(all;​;​;​on) /* Hide "0" scaling label. */

11

AxisLine(all;​0) /* Hide axes. */

12

AxisMajorTicks(all;​0) /* Hide tick marks. */

13

AxisLabelText(all;​"A";​"B";​"C";​"D";​"E")

14

/* Set up grid. */

15

MajorGridLineColors(all;​all;​#d0d0d0)

16

CloseDrawing()

SCALING_07

Dates and/or times can also be used as the minimum and maximum value (time axis). Additional information can be found in Date & Time.

SCALING_08
1

OpenDrawing(250;​150)

2

ChartData(2018-08-15 2018-08-24)

3

GanttChart()

4

/* Set up styles. */

5

FillStyle(1;​#4682b420)

6

BorderStyle(1;​;​1.5;​#4682b4)

7

/* Set up axes. */

8

Scaling(x;​linear)

9

AxisLine(all;​0)

10

AxisMajorTicks(all;​0)

11

AxisMajorTickLabelStyle(x;​;​;​;​;​;​-90)

12

AxisMajorTickLabelOptions(x;​;​;​3)

13

/* Set up grid. */

14

MajorGridLineWidths(all;​all;​0.25)

15

CloseDrawing()

SCALING_08
SCALING_09
1

OpenDrawing(250;​100)

2

ChartData(2016-05-22 2018-06-14)

3

GanttChart(label)

4

/* Set up styles. */

5

FillStyle(1;​#4682b420)

6

BorderStyle(1;​;​1.5;​#4682b4)

7

Labeltexts(1;​"|u| days")

8

/* Set up axes. */

9

Scaling(x;​linear;​2016/1/1;​2018/12/31;​;​4)

10

AxisLine(all;​0)

11

AxisMajorTicks(all;​0)

12

AxisMinorTicks(all;​0)

13

AxisMajorTickLabelTexts(x;​"|YYYY|")

14

/* Set up grid. */

15

MajorGridLineWidths(all;​all;​0.5)

16

MinorGridLineWidths(y;​x;​0.5)

17

CloseDrawing()

SCALING_09

In the event of a time axis, major and minor intervals can be defined by scaling constants.

SCALING_10
1

OpenDrawing(250;​100)

2

DateTimeOptions(ymd;​2)

3

ChartData(2018-08-14 2018-08-22 2018-08-27&12:00;​

4

19 28 23)

5

AreaChart2D(;​1)

6

/* Set up styles. */

7

FillStyle(1;​#4682b420)

8

BorderStyle(1;​;​1.5;​#4682b4)

9

/* Set up axes. */

10

Scaling(x;​linear;​;​;​week)

11

AxisLine(all;​0)

12

AxisMajorTicks(all;​0)

13

AxisMajorTickLabelTexts(x;​"Week #|WY|")

14

/* Set up grid. */

15

MajorGridLineWidths(all;​all;​0.25)

16

CloseDrawing()

SCALING_10
SCALING_11
1

OpenDrawing(300;​120)

2

DateTimeOptions(ymd;​2)

3

ChartData(2018-08-10 2018-08-22 2018-08-25 2018-08-27)

4

Ganttchart()

5

/* Set up styles. */

6

FillStyle(1;​#4682b420)

7

BorderStyle(1;​;​1.5;​#4682b4)

8

/* Set up axes. */

9

Scaling(x;​linear;​;​;​week;​day)

10

AxisLine(all;​0)

11

AxisMajorTicks(all;​0)

12

AxisMinorTicks(all;​0)

13

AxisMajorTickLabelTexts(x;​"WK |WY|")

14

AxisMajorTickLabelOptions(x;​out;​;​35)

15

AxisMinorTickLabelTexts(x;​"|M/D|")

16

AxisMinorTickLabelStyle(x;​;​;​;​;​;​-90)

17

AxisMinorTickLabelOptions(x;​;​;​3)

18

/* Set up grid. */

19

MajorGridLineWidths(all;​all;​0.5)

20

MinorGridLineWidths(y;​x;​0.5)

21

CloseDrawing()

SCALING_11
SCALING_12
1

OpenDrawing(250;​120)

2

DateTimeOptions(ymd;​2)

3

ChartData(2018-06-21 2018-8-22 2018-9-27;​

4

19 28 23)

5

AreaChart2D(;​1)

6

/* Set up styles. */

7

FillStyle(1;​#4682b420)

8

BorderStyle(1;​;​1.5;​#4682b4)

9

/* Set up axes. */

10

Scaling(x;​linear;​;​;​month;​week)

11

AxisLine(all;​0)

12

AxisMajorTicks(all;​0)

13

AxisMinorTicks(all;​0)

14

AxisMajorTickLabelTexts(x;​"|Mon|")

15

AxisMajorTickLabelOptions(x;​in)

16

AxisMinorTickLabelTexts(x;​"WK |WY|";​"")

17

AxisMinorTickLabelStyle(x;​;​;​;​;​;​-90)

18

AxisMinorTickLabelOptions(x;​;​;​3)

19

/* Set up grid. */

20

MajorGridLineWidths(all;​all;​1 2 2)

21

MinorGridLineWidths(y;​x;​0.5)

22

GridFrame(xy;​0.5;​#555)

23

CloseDrawing()

SCALING_12
SCALING_13
1

OpenDrawing(300;​150)

2

ChartData(11:30 16:15;​

3

9:30 12:00 13:30 16:50;​

4

10:15 15:30)

5

GanttChart(label;​75)

6

/* Set up styles. */

7

FillStyle(1;​#4682b420)

8

FillStyle(2;​#daa52020)

9

FillStyle(3;​#6b8e2320)

10

BorderStyle(1;​;​1.5;​#4682b4)

11

BorderStyle(2;​;​1.5;​#daa520)

12

BorderStyle(3;​;​1.5;​#6b8e23)

13

/* Set up axes. */

14

Scaling(x;​linear;​;​;​hour;​minute15)

15

ScalingOptions(y;​on) /* y-scale top to bottom. */

16

AxisLine(all;​0)

17

AxisMajorTicks(all;​0)

18

AxisMinorTicks(all;​0)

19

AxisMajorTickLabelTexts(x;​"|h:mm|")

20

AxisMajorTickLabelStyle(x;​;​;​;​;​;​-90)

21

AxisMajorTickLabelOptions(x;​;​;​3)

22

/* Set up grid. */

23

MajorGridLineWidths(all;​all;​0.25)

24

MinorGridLineWidths(y;​x;​0.25)

25

GridFrame(xy;​0.5;​#555)

26

CloseDrawing()

SCALING_13

The arguments logBaseValue and useEquidistantLogScaling are solely used for logarithmic scaling. The base of the logarithm is defined by using the argument logBaseValue. If no base is defined, the decimal logarithm (logBaseValue =​ 10) is used for scaling. By activating the argument useEquidistantLogScaling = on, only scaling values, which are a multiple of the base, are used; for example, for a logarithmic scaling with a base of 10, only values such as 0.01, 0.1, 1, 10, 100, 1000, etc. are used.

SCALING_14
1

OpenDrawing(250;​150)

2

ChartData(36 18 14 18 13 8 5)

3

LineChart(symbol;​on)

4

/* Set up styles. */

5

LineStyle(1;​poly;​1.0;​darkRed)

6

SymbolStyle(1;​circle;​5;​1;​darkRed;​;​white)

7

/* Set up axes. */

8

Scaling(y;​log;​;​;​;​9;​10;​on) /* 9 minor intervals. */

9

AxisLine(all;​0)

10

AxisMajorTicks(x;​5;​1;​#333;​;​out)

11

AxisMajorTicks(y;​0)

12

AxisMinorTicks(all;​0)

13

/* Set up grid. */

14

MajorGridLineWidths(y;​x;​0) /* Hide vertical grid lines. */

15

MajorGridLineWidths(x;​y;​1)

16

MinorGridLineWidths(x;​y;​0.75)

17

CloseDrawing()

SCALING_14
SCALING_15
1

OpenDrawing(250;​150)

2

ChartData(36 18 14 18 13 8 5)

3

LineChart(symbol;​on)

4

/* Set up styles. */

5

LineStyle(1;​poly;​1.0;​darkRed)

6

SymbolStyle(1;​circle;​5;​1;​darkRed;​;​white)

7

/* Set up axes. */

8

Scaling(y;​​log;​;​;​;​;​2;​on) /* Logarithmic base 2 */

9

AxisLine(all;​0)

10

AxisMajorTicks(x;​5;​0.25;​#333;​;​out)

11

AxisMajorTicks(y;​0)

12

/* Set up grid. */

13

MajorGridLineWidths(y;​x;​0) /* Hide vertical grid lines. */

14

MajorGridLineWidths(x;​y;​0.25)

15

CloseDrawing()

SCALING_15
Scroll to Top
Your browser is out-of-date!

Update your browser to view this website correctly. Update my browser now

×