Advertisement
Guest User

Untitled

a guest
Apr 7th, 2014
147
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 5 2.05 KB | None | 0 0
  1. <!DOCTYPE html>
  2. <html lang="en">
  3.     <head>
  4.         <meta charset="utf-8">
  5.         <title>
  6.             title
  7.         </title>
  8.     </head>
  9.     <body>
  10.         <script src="http://d3js.org/d3.v3.min.js"></script> <script src="http://dimplejs.org/dist/dimple.v1.1.5.min.js"></script>
  11.         <link href="assets3/css/bootstrap.min.css" rel="stylesheet">
  12.         <link href="assets3/css/my_bootstrap_styles.css" rel="stylesheet">
  13.         <script src="assets3/js/jquery-1.10.2.min.js"></script>
  14.         <div id="chartContainer">
  15.             <div id="gaa_chart" />
  16.             <div id="svpct_chart" />
  17.         </div>
  18.         <script type="text/javascript">
  19.             var svg = dimple.newSvg("#gaa_chart", 500, 400);
  20.             var data = [
  21.                 {'Season':'ABC','Date':'2014-05-01','SPCT':'0.975'},
  22.                 {'Season':'ABC','Date':'2014-05-02','SPCT':'0.980'},
  23.                 {'Season':'ABC','Date':'2014-05-03','SPCT':'0.975'},
  24.                 {'Season':'ABC','Date':'2014-05-04','SPCT':'0.970'},
  25.                 {'Season':'ABC','Date':'2014-05-05','SPCT':'0.975'},
  26.                 {'Season':'ABC','Date':'2014-05-06','SPCT':'0.980'},
  27.                 {'Season':'ABC','Date':'2014-05-07','SPCT':'0.985'},
  28.                 {'Season':'ABC','Date':'2014-05-08','SPCT':'0.950'},
  29.                 {'Season':'ABC','Date':'2014-05-09','SPCT':'0.975'},
  30.                 {'Season':'ABC','Date':'2014-05-10','SPCT':'0.980'},
  31.                 {'Season':'ABC','Date':'2014-05-11','SPCT':'0.985'},
  32.                 {'Season':'ABC','Date':'2014-05-12','SPCT':'0.990'},
  33.                 {'Season':'ABC','Date':'2014-05-13','SPCT':'0.980'},
  34.                 {'Season':'ABC','Date':'2014-05-14','SPCT':'0.980'},
  35.                 {'Season':'ABC','Date':'2014-05-15','SPCT':'0.975'},
  36.                 {'Season':'ABC','Date':'2014-05-16','SPCT':'0.970'},
  37.             ]
  38.            
  39.               var myChart = new dimple.chart(svg, data);
  40.               myChart.setBounds(60, 30, 400, 300)
  41.               myChart.addCategoryAxis("x", "Date");
  42.               var axis = myChart.addMeasureAxis("y", "SPCT");
  43.               axis.overrideMin = 0.9;
  44.               myChart.addSeries("Season", dimple.plot.line);
  45.               myChart.addLegend(0, 10, 510, 20, "right");
  46.               myChart.draw();
  47.           </script>
  48.         <!-- Include all compiled plugins (below), or include individual files as needed -->
  49.         <script src="assets3/js/bootstrap.min.js"></script>
  50.     </body>
  51. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement