jqplot

jqplot pointlabels off position in IE9+

帅比萌擦擦* 提交于 2019-12-13 02:54:19
问题 In IE9+, the point labels seem to only occupy the 4th quadrant of the chart (as if the entire chart was scaled down) when using jqplotToImageStr. The chart displays normally otherwise (within the page when divs are used for the labels I believe) 回答1: Fixed it by adding the css rule: .jqplot-point-label { text-align: left; } this is because the toimage function has a handler for center aligned text (which is the default), which is causing things to be positioned incorrectly. The culprit: if ($

JQPlot - Stacked Horizontal Bar Chart - No Bars When Stacked

女生的网名这么多〃 提交于 2019-12-13 02:34:54
问题 Having a strange issue with jqplot. I've created a horizontal bar chart with 2 series and 5 labels; all populated with variables from a table. var plot1 = $.jqplot('chart1', [ [[SERIESA[0],TITLE[0]], [SERIESA[1],TITLE[1]], [SERIESA[2],TITLE[2]], [SERIESA[3],TITLE[3]], [SERIESA[4],TITLE[4]]], [[SERIESB[0],TITLE[0]], [SERIESB[1],TITLE[1]], [SERIESB[2],TITLE[2]], [SERIESB[3],TITLE[3]], [SERIESB[4],TITLE[4]]]], { seriesDefaults: { renderer:$.jqplot.BarRenderer, // Show point labels to the right (

jqplot highlighter a line when mouse is over it

妖精的绣舞 提交于 2019-12-13 00:39:06
问题 I am using jqplot to generate several line plots, and would like to add the highlight feature to it. In detail, once your mouse is over this line, it will highlight itself (change color). I have see this feature in bar plot (example). Is there a way to introduce this to line plot? Here is the demo of my code. 回答1: This feature, at least to my knowledge, is not provided out of the box by the jqPlot . For this reason the 'easiest' is to add it yourself. I did something of this sort a while back

Hide first yaxis label

女生的网名这么多〃 提交于 2019-12-12 21:22:57
问题 I need to hide the label -200 in yaxis, is there any way to hide the first yaxis label? So the yaxis label result will be [empty] ,0, 200, 400, 600, 800 回答1: What i did is return an empty string for negative value. tickOptions: { formatter: function (format, value) { if (value < 0) { return ' '; } else { return value } } } 回答2: Let say your chart is included in a div with "chart1" as id, you can hide the first yaxis label using : $("div#chart1 div.jqplot-yaxis div.jqplot-yaxis-tick:nth-child

Tooltips working when entering jqplot pie but not when moving from slice to slice (Firefox only affected)

大兔子大兔子 提交于 2019-12-12 18:41:30
问题 Tooltips work okay when entering piechart 'from outside' but the transition between slices causes the tooltip to disappear & the new one is not created. Here is my jsfiddle snippet, closely based on helpful advice from this SO answer. I know that how to get tooltips working for pie as a whole as have see another jsfiddle doing just that but I want the tooltip on top of the specific slice. I have seen the bubble plots example on http://www.jqplot.com but since it uses plot1b.axes.xaxis etc I

jqplot donut chart label/legend color and line

不羁岁月 提交于 2019-12-12 17:04:14
问题 I am working with jqplot donut and all seems to be working fine except that I am unable to give color to donut chart value % and a line that should link value % and the chart. I will use screen shots to better explain what my output is what i am trying to achieve This is what my output looks like Using this code var plot1; var storedData; $(document).ready(function () { storedData = [ ['Take home pay', 44228.33], ['Tax', 8771.67], ['Super', 4162.5 ], ['Regular expenses', 0 ], ['Unallocated',

turning pointLabels on and off in jqplot

好久不见. 提交于 2019-12-12 11:37:29
问题 I am trying to turn pointLabels on and off programmatically. I thought it would work something like this: var data_ = [[1,1],[2,5],[4,9]]; var graph = $.jqplot(id_graph, [data_], { series:[{pointLabels: { show:true } }] } ); graph.series[0].pointLabels.show=false; graph.replot(); However, this still displays the point labels. Thanks for any help! 回答1: althoug this post is old I found a solution for the problem: var data_ = [[1,1],[2,5],[4,9]]; var graph = $.jqplot(id_graph, [data_], { series:

Creating jqplot graph using php

限于喜欢 提交于 2019-12-12 09:58:55
问题 I'm not really good at English sorry. I don't know how to pass values to jqplot application. the php webpage shows [{"PER":"23"},{"PER":"47"},{"PER":"86"},{"PER":"25"},{"PER":"74"}] which came from mysql server. the table has one column and values are 23, 47, 86, 25, 74 this is the php code. <?php mysql_connect("localhost","root","autoset"); mysql_select_db("test"); $q=mysql_query("SELECT PER FROM Evaluation"); while($e=mysql_fetch_assoc($q)) $output[]=$e; print(json_encode($output)); mysql

Including jqPlot files in particular order

你说的曾经没有我的故事 提交于 2019-12-12 09:11:53
问题 Is there a particular order that jQPlot has to be included in a header? Currently I'm using jQMobile, but for some reason my jqPlot BarRenderer.js isn't being recognized... <head> <!-- CSS --> <link rel="stylesheet" href="./signup.css"> <link rel="stylesheet" href="http://code.jquery.com/mobile/1.1.1/jquery.mobile-1.1.1.min.css" /> <link rel="stylesheet" type="text/css" href="http://dev.jtsage.com/cdn/simpledialog/latest/jquery.mobile.simpledialog.min.css" /> <!-- Modernizer --> <script type=

Having problems with jqPlot bar chart

孤街浪徒 提交于 2019-12-12 08:23:55
问题 I'm using jqPlot to create a bar graph, but I ran into a few problems. Problem 1: The first and last bars on the graph are cut off. Only half of it is displaying Problem 2: I don't want my data points to span the entire x-axis. Is there to not have the data span the entire x-axis? ex: This is what is does right now. This is the data I am passing into it var chartData = [["19-Jan-2012",2.61],["20-Jan-2012",5.00],["21-Jan-2012",6.00]] This is the jquery I am using. // Plot chart function