• Edit
  • Download
    1. <!DOCTYPE html>
    2. <html>
    3.  
    4. <head>
    5. <meta charset="utf-8">
    6. <title>ZingSoft Demo</title>
    7.  
    8. <script nonce="undefined" src="https://cdn.zingchart.com/zingchart.min.js"></script>
    9. <style></style>
    10. </head>
    11.  
    12. <body>
    13. <div id='myChart'></div>
    14. <script>
    15. ZC.LICENSE = ["569d52cefae586f634c54f86dc99e6a9", "b55b025e438fa8a98e32482b5f768ff5"];
    16. let chartConfig = {
    17. type: 'scatter',
    18. scaleX: {
    19. values: '0:100:10',
    20. item: {
    21. fontSize: 10
    22. },
    23. guide: {
    24. visible: false
    25. }
    26. },
    27. scaleY: {
    28. values: '0:100:20',
    29. item: {
    30. fontSize: 10
    31. },
    32. guide: {
    33. lineStyle: 'solid'
    34. },
    35. minorTicks: 9,
    36. minorGuide: {
    37. alpha: 1
    38. },
    39. markers: [{
    40. type: 'area',
    41. range: [0, 20],
    42. backgroundColor: '#C5CAE9'
    43. },
    44. {
    45. type: 'area',
    46. range: [20, 40],
    47. backgroundColor: '#9FA8DA'
    48. },
    49. {
    50. type: 'area',
    51. range: [40, 60],
    52. backgroundColor: '#7986CB'
    53. },
    54. {
    55. type: 'area',
    56. range: [60, 80],
    57. backgroundColor: '#5C6BC0'
    58. },
    59. {
    60. type: 'area',
    61. range: [80, 100],
    62. backgroundColor: '#3F51B5'
    63. }
    64. ],
    65. },
    66. scaleY2: {
    67. values: '0:100:20',
    68. item: {
    69. fontSize: 10
    70. },
    71. guide: {
    72. visible: false
    73. },
    74. minorTicks: 9,
    75. },
    76. crosshairX: {
    77. alpha: 0.3,
    78. lineWidth: 5,
    79. marker: {
    80. backgroundColor: 'white',
    81. borderColor: '#3F51B5',
    82. borderWidth: 1,
    83. size: 5,
    84. },
    85. plotLabel: {
    86. alpha: 0.7,
    87. borderColor: '#303F9F',
    88. borderRadius: 3,
    89. fontColor: '#303F9F',
    90. placement: 'node-top',
    91. multiple: true,
    92. text: '<strong>%t:</strong> %v',
    93. textAlpha: 1
    94. },
    95. scaleLabel: {
    96. backgroundColor: '#303F9F',
    97. borderRadius: 3
    98. }
    99. },
    100. crosshairY: {
    101. alpha: 0.3,
    102. lineWidth: 5,
    103. type: 'multiple',
    104. scaleLabel: {
    105. backgroundColor: '#303F9F',
    106. borderRadius: 3
    107. }
    108. },
    109. plot: {
    110. marker: {
    111. backgroundColor: '#9FA8DA #3F51B5'
    112. },
    113. tooltip: {
    114. visible: false
    115. }
    116. },
    117. series: [{
    118. values: [
    119. [21.5, 23.5],
    120. [23.1, 30.3],
    121. [25.1, 34.3],
    122. [30.2, 34.2],
    123. [30.9, 29.3],
    124. [31.9, 39.9],
    125. [34.2, 50.5],
    126. [35.5, 33.3],
    127. [39.1, 39.1],
    128. [53.2, 54.3],
    129. [57.1, 60.1],
    130. [59.5, 60.5],
    131. [61.6, 61.7],
    132. [64.1, 64.2],
    133. [69.5, 70.9],
    134. [70.3, 80.9],
    135. [71.7, 63.7],
    136. [75.4, 83.4],
    137. [80.3, 89.4],
    138. [80.9, 84.3],
    139. [85.1, 83.1],
    140. [85.3, 87.5],
    141. [89.3, 84.9],
    142. [90.1, 91.2],
    143. [91.3, 95.3],
    144. [92.4, 90.8],
    145. [93.5, 98.7],
    146. [95.5, 96.5],
    147. [96.1, 90.5],
    148. [99.1, 99.1]
    149. ],
    150. text: 'Marker'
    151. }]
    152. };
    153.  
    154. zingchart.render({
    155. id: 'myChart',
    156. data: chartConfig,
    157. height: 400,
    158. width: '100%'
    159. });
    160. </script>
    161. </body>
    162.  
    163. </html>
    1. <!DOCTYPE html>
    2. <html>
    3.  
    4. <head>
    5. <meta charset="utf-8">
    6. <title>ZingSoft Demo</title>
    7.  
    8. <script src="https://cdn.zingchart.com/zingchart.min.js"></script>
    9. </head>
    10.  
    11. <body>
    12. <div id='myChart'></div>
    13. </body>
    14.  
    15. </html>
    1.  
    1. let chartConfig = {
    2. type: 'scatter',
    3. scaleX: {
    4. values: '0:100:10',
    5. item: {
    6. fontSize: 10
    7. },
    8. guide: {
    9. visible: false
    10. }
    11. },
    12. scaleY: {
    13. values: '0:100:20',
    14. item: {
    15. fontSize: 10
    16. },
    17. guide: {
    18. lineStyle: 'solid'
    19. },
    20. minorTicks: 9,
    21. minorGuide: {
    22. alpha: 1
    23. },
    24. markers: [{
    25. type: 'area',
    26. range: [0, 20],
    27. backgroundColor: '#C5CAE9'
    28. },
    29. {
    30. type: 'area',
    31. range: [20, 40],
    32. backgroundColor: '#9FA8DA'
    33. },
    34. {
    35. type: 'area',
    36. range: [40, 60],
    37. backgroundColor: '#7986CB'
    38. },
    39. {
    40. type: 'area',
    41. range: [60, 80],
    42. backgroundColor: '#5C6BC0'
    43. },
    44. {
    45. type: 'area',
    46. range: [80, 100],
    47. backgroundColor: '#3F51B5'
    48. }
    49. ],
    50. },
    51. scaleY2: {
    52. values: '0:100:20',
    53. item: {
    54. fontSize: 10
    55. },
    56. guide: {
    57. visible: false
    58. },
    59. minorTicks: 9,
    60. },
    61. crosshairX: {
    62. alpha: 0.3,
    63. lineWidth: 5,
    64. marker: {
    65. backgroundColor: 'white',
    66. borderColor: '#3F51B5',
    67. borderWidth: 1,
    68. size: 5,
    69. },
    70. plotLabel: {
    71. alpha: 0.7,
    72. borderColor: '#303F9F',
    73. borderRadius: 3,
    74. fontColor: '#303F9F',
    75. placement: 'node-top',
    76. multiple: true,
    77. text: '<strong>%t:</strong> %v',
    78. textAlpha: 1
    79. },
    80. scaleLabel: {
    81. backgroundColor: '#303F9F',
    82. borderRadius: 3
    83. }
    84. },
    85. crosshairY: {
    86. alpha: 0.3,
    87. lineWidth: 5,
    88. type: 'multiple',
    89. scaleLabel: {
    90. backgroundColor: '#303F9F',
    91. borderRadius: 3
    92. }
    93. },
    94. plot: {
    95. marker: {
    96. backgroundColor: '#9FA8DA #3F51B5'
    97. },
    98. tooltip: {
    99. visible: false
    100. }
    101. },
    102. series: [{
    103. values: [
    104. [21.5, 23.5],
    105. [23.1, 30.3],
    106. [25.1, 34.3],
    107. [30.2, 34.2],
    108. [30.9, 29.3],
    109. [31.9, 39.9],
    110. [34.2, 50.5],
    111. [35.5, 33.3],
    112. [39.1, 39.1],
    113. [53.2, 54.3],
    114. [57.1, 60.1],
    115. [59.5, 60.5],
    116. [61.6, 61.7],
    117. [64.1, 64.2],
    118. [69.5, 70.9],
    119. [70.3, 80.9],
    120. [71.7, 63.7],
    121. [75.4, 83.4],
    122. [80.3, 89.4],
    123. [80.9, 84.3],
    124. [85.1, 83.1],
    125. [85.3, 87.5],
    126. [89.3, 84.9],
    127. [90.1, 91.2],
    128. [91.3, 95.3],
    129. [92.4, 90.8],
    130. [93.5, 98.7],
    131. [95.5, 96.5],
    132. [96.1, 90.5],
    133. [99.1, 99.1]
    134. ],
    135. text: 'Marker'
    136. }]
    137. };
    138.  
    139. zingchart.render({
    140. id: 'myChart',
    141. data: chartConfig,
    142. height: 400,
    143. width: '100%'
    144. });