- Learning jqPlot
- Scott Gottreu
- 98字
- 2021-09-03 09:49:41
Passing in both x and y values
The next option to pass in data to the chart is to use a two-dimensional array. Our inner array contains individual arrays, which in turn contain the value for x axis followed by the value for y axis. When we include both x
and y
values, our data points may not increment at a constant interval, as was the case in our previous chart:
<script> $(document).ready(function(){ var secondPlot = $.jqplot ('secondChart', [[[5,4],[10,7],[15,6],[20,9]]]); }); </script> <div id="secondChart" style="width:400px;"></div>
We load this new chart in our web browser, and the results are as shown in the following figure:

推薦閱讀
- Practical Data Analysis Cookbook
- Spring Boot 2實戰之旅
- DevOps:軟件架構師行動指南
- 數據科學實戰手冊(R+Python)
- AngularJS入門與進階
- The DevOps 2.3 Toolkit
- Bootstrap Essentials
- 名師講壇:Spring實戰開發(Redis+SpringDataJPA+SpringMVC+SpringSecurity)
- Python編程從0到1(視頻教學版)
- 軟件供應鏈安全:源代碼缺陷實例剖析
- Spring MVC+MyBatis開發從入門到項目實踐(超值版)
- Getting Started with Polymer
- 數據結構:Python語言描述
- 高性能PHP 7
- Java EE基礎實用教程