Advertisement
Guest User

Untitled

a guest
Jun 19th, 2019
102
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 3.41 KB | None | 0 0
  1.  
  2. <html lang="en">
  3. <head>
  4.     <meta charset="utf-8" />
  5.     <title>Hye Source</title>
  6.     <meta name="description" content="Alhusna Apps">
  7.     <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, shrink-to-fit=no">
  8.    
  9. </head>
  10. <body>
  11.     <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
  12.     <script src="http://code.highcharts.com/highcharts.js"></script>
  13.     <script src="http://code.highcharts.com/modules/exporting.js"></script>
  14.     <script src="https://rawgit.com/phpepe/highcharts-regression/master/highcharts-regression.js"></script>
  15.     <div id="container" style="min-width: 310px; height: 400px; margin: 0 auto"></div>
  16.     <script>
  17.         $(function () {
  18.             $('#container').highcharts({
  19.                 chart: {
  20.                     type: 'scatter',
  21.                     zoomType: 'xy'
  22.                 },
  23.                 title: {
  24.                     text: 'Polynomial regression - Fuzzyparadoxx Polynomial challenge'
  25.                 },
  26.                 subtitle: {
  27.                     text: 'Source: Hye Source 2019'
  28.                 },
  29.                 xAxis: {
  30.                     title: {
  31.                         enabled: true,
  32.                         text: 'Height (cm)'
  33.                     },
  34.                     startOnTick: true,
  35.                     endOnTick: true,
  36.                     showLastLabel: true
  37.                 },
  38.                 yAxis: {
  39.                     title: {
  40.                         text: 'Weight (kg)'
  41.                     }
  42.                 },
  43.                 legend: {
  44.                     layout: 'vertical',
  45.                     align: 'left',
  46.                     verticalAlign: 'top',
  47.                     x: 100,
  48.                     y: 70,
  49.                     floating: true,
  50.                     backgroundColor: '#FFFFFF',
  51.                     borderWidth: 1
  52.                 },
  53.                 plotOptions: {
  54.                     scatter: {
  55.                         marker: {
  56.                             radius: 5,
  57.                             states: {
  58.                                 hover: {
  59.                                     enabled: true,
  60.                                     lineColor: 'rgb(100,100,100)'
  61.                                 }
  62.                             }
  63.                         },
  64.                         states: {
  65.                             hover: {
  66.                                 marker: {
  67.                                     enabled: false
  68.                                 }
  69.                             }
  70.                         },
  71.                         tooltip: {
  72.                             headerFormat: '<b>{series.name}</b><br>',
  73.                             pointFormat: '{point.x} cm, {point.y} kg'
  74.                         }
  75.                     }
  76.                 },
  77.                 series: [{
  78.                     regression: true,
  79.                     regressionSettings: {
  80.                         type: 'polynomial',
  81.                         color: 'rgba(223, 183, 83, .9)',
  82.                         dashStyle: 'dash'
  83.                     },
  84.                     name: 'Test input',
  85.                     color: 'rgba(223, 83, 83, .5)',
  86.                     data: [
  87.                         [1, 1],
  88.                         [2, 3],
  89.                         [3, 9],
  90.                     ]
  91.  
  92.                 }]
  93.             });
  94.         });
  95.     </script>
  96. </body>
  97. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement