jqplot

Why does my chart (jqplot) fail to render until I press a button when integrated with zk?

核能气质少年 提交于 2020-01-06 05:02:36
问题 I am using zk to display a page and as part of that I include an html/js page that holds the chart I want to display using jqplot. If I load the html file by itself the plot shows up fine. When I include it in the zul page, it fails to show up. However there is a reset button (it resets the zoom level on the chart) that does appear. If I hit that button, the chart shows up fine. I have no idea why this is happening or how to fix it. Does anyone have any ideas? test.html... <span id="test"

Implement graph using jQplot

痴心易碎 提交于 2020-01-06 03:52:06
问题 My need is to implement following graph I know about stacked chart, but here there are axis points labels (In my need there is no any axes point labels), and this is from Y-axis. I am confused how can I implement it. Can you please help me? Any link will also be helpful. Update : I am trying a code snippet <script type="text/javascript" language="javascript"> $(document).ready(function(){ var line1 = [14]; var line2 = [77]; var plot4 = $.jqplot('test2', [line1, line2], { title: '1 Mobility

Add Legend to Donut Chart - jqPlot

最后都变了- 提交于 2020-01-06 03:13:07
问题 OK, this should be relatively simple : I'm adding a donut chart, which does work However, the 'legend' (like Head (+) along with the corresponding colour) does NOT show up. Code : $(document).ready(function(){ var s1 = [['Head (+)',<?php echo $headScore; ?>], ['Head (-)',<?php echo 6-$headScore; ?>]]; var s2 = [['Body (+)',<?php echo $totalScore-$headScore; ?>], ['Body (-)',<?php echo 7-$totalScore+$headScore; ?>]]; var plot3 = $.jqplot('linkchart', [s1,s2], { title:"Score Profile",

How can I set circle size of the pie chart with jqplot?

女生的网名这么多〃 提交于 2020-01-05 07:28:46
问题 I ned to set the circle size for pie chart with jqplot....I have following code snippet... var plot = jQuery.jqplot ('chart', [data], { seriesDefaults: { renderer: jQuery.jqplot.PieRenderer, rendererOptions: { showDataLabels: true }, pointLabels: { show: true } }, diameter : 1, legend: { show:true, location: 'e', placement: 'inside' }, title: { fontSize:'14px', fontWeight: 'bold', fontFamily: 'Arial', show: true } } is this the right way to set diameter for the circle? 回答1: It should be under

jqplot: elements of stacked bar chart missing

。_饼干妹妹 提交于 2020-01-05 06:38:24
问题 I've been struggeling with the following for quite some time now.. Hopefully someone can help me out. What I'm trying to do: Using jqplot I'm trying to combine a horizontal stacked bar chart with a line chart. The stacked bar chart should contain five values. The line chart should cross the stacked bar chart. What I've come up with so far: I've managed to build the horizontal stacked bar chart and the line crosses it as it should. The problem: My stacked bar chart now shows three blocks

jqPlot Pie Chart Tooltips

瘦欲@ 提交于 2020-01-05 06:37:06
问题 Am I right in thinking that the Hightlighter class in jqPlot does not handle tooltips for the PieRenderer? I've spent quite a while trying to get them to work however I can't seem to get it to show the tooltip. If I am right, is there a way to handle the rollover of a segment and pass the data to a third party jQuery tooltip? Thanks. 回答1: Looking through the issues for jqplot, it would seem that there have been a few requests for this functionality, but it has not yet been implemented. Based

Is it possible to write legend to a separate division with jqPlot

*爱你&永不变心* 提交于 2020-01-05 05:58:39
问题 I want to write the legend to a separate div, is this possible with jqPlot legend: { show: true, placement: 'outside', fontSize: '11px', location: 'n' } 回答1: Here our the two function which you can use: function graphLegendCreation(cnt){ var parentNode = _g("dmGraphLegend")//trying to get the div element with id dmGraphLegend , newLegendItemNode = Util.ce("span") //creating an span element , newLegendItemSelect = Util.cep("input", { //creating an input element "type":"checkbox", "name":

dataRender in jqPlot ASP.NET from an AJAX Request

浪子不回头ぞ 提交于 2020-01-04 21:42:10
问题 I am trying to render a jqPlot bar chart from an AJAX request and I can't get it to work. I have the following JavaScript code: var ajaxDataRenderer = function (url, plot) { var ret = null; $.ajax({ // have to use synchronous here, else returns before data is fetched async: false, url: url, contentType: "application/json; charset=utf-8", dataType: 'json', success: function (data) { ret = data; } }); return ret; }; var jsonurl = "WebService1.asmx/HelloWorld"; plo12 = $.jqplot('chart2', jsonurl

Right align bars JQPlot

大兔子大兔子 提交于 2020-01-03 05:34:06
问题 I have produced the following graph using jqPlot, however for some reason the bars start in the middle of the xAxis. I need to move them to the right, i've looked at the docs and couldn't work it out. any suggestions? $(document).ready(function(){ var ok_before = [4, 3, 1, 0]; var ok_bars = [3, 4, 5, 4]; var ok_after = [1, 1, 2, 4]; var err_before = [5, 0, 2, 0]; var err_bars = [1, 0, 2, 0]; var err_after = [2, 8, 4, 8]; var dateticks = [['2014-01-01' ], ['2014-01-02' ], ['2014-01-03' ], [

Constructing Json for JqPlot Bar Charts

狂风中的少年 提交于 2020-01-03 02:55:37
问题 I have managed to create something to populate the JqPlot pie chart (very hard coded – it will be automated). Here is how I’ve done it: public ActionResult PieChart() { return View(); } public ActionResult PieChartJSON() { List<PieChartData> sampleData = new List<PieChartData>(); PieChartData test = new PieChartData(); PieChartData test2 = new PieChartData(); PieChartData test3 = new PieChartData(); PieChartData test4 = new PieChartData(); PieChartData test5 = new PieChartData(); test.Label =