Elvina456 / flot

Automatically exported from code.google.com/p/flot
MIT License
0 stars 0 forks source link

Labels for X and Y axis #42

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
is there any way for displaying labels for X axis and Y axis?

Original issue reported on code.google.com by koneru.chowdary on 3 Jun 2008 at 9:55

GoogleCodeExporter commented 8 years ago
If you look at my flot fork (github.com/thenduks/flot) there is 
rudimentary/early
support for axis labels. Right now x and y both work in firefox 3, and x works
everywhere (I think :)). There's still some issues with the yaxis for browsers 
other
than firefox 3.

Original comment by ryan.fun...@gmail.com on 12 Aug 2008 at 4:52

GoogleCodeExporter commented 8 years ago

Original comment by olau%iol...@gtempaccount.com on 10 Sep 2008 at 8:07

GoogleCodeExporter commented 8 years ago
This is mostly pending on the ability to display rotated text. There was a 
thread on
the mailing list about it some months ago. I think it's possible with enough 
hacking,
but is separate enough that I think that the hacking should be done in another
library which Flot can then use.

Original comment by olau%iol...@gtempaccount.com on 1 Oct 2008 at 8:06

GoogleCodeExporter commented 8 years ago
This keeps coming up, the latest discussion is here for reference:

http://groups.google.com/group/flot-graphs/browse_thread/thread/3e2585758c4f0e6e
/d9aa96a2909a4f00

Original comment by olau%iol...@gtempaccount.com on 23 Mar 2009 at 6:15

GoogleCodeExporter commented 8 years ago
jqplot have support for this, maybe this can be ported here?
http://www.jqplot.com/tests/axisLabelTests.php

Original comment by Oystein.Stromme@gmail.com on 9 Sep 2009 at 6:21

GoogleCodeExporter commented 8 years ago
This is not an Enhancement.  This is a pre-requisite to any chart. Could you 
modify
the ticket priority? 

Original comment by sidnei.b...@gmail.com on 24 Sep 2009 at 1:35

GoogleCodeExporter commented 8 years ago
Any updates yet on this feature being implemented?

Original comment by dans...@gmail.com on 16 Oct 2009 at 3:41

GoogleCodeExporter commented 8 years ago
Oystein: yeah. Canvas text support is beginning to emerge in the browsers. If 
I'm not
mistaken, support for it got added to excanvas some time ago. If someone would 
cook
up a patch and smoketest it in various browsers, it would certainly speed up 
the process.

sidnei, danshao: It'll appear faster if you help.

Original comment by olau%iol...@gtempaccount.com on 21 Oct 2009 at 3:39

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
It doesn't have to be rotated - horizontal text would be good enough.

Original comment by eaton....@gmail.com on 13 Jan 2010 at 7:13

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Why on earth is this only "medium" priority? A plot without axis labels is 
useless.

Original comment by substant...@gmail.com on 9 Mar 2010 at 6:23

GoogleCodeExporter commented 8 years ago
Why is this only an "enhancement"? Sounds like a bug to me.

Original comment by dans...@gmail.com on 10 Mar 2010 at 9:03

GoogleCodeExporter commented 8 years ago
I also believe the priority of this should be higher ...

Original comment by prodan.c...@gmail.com on 29 Apr 2010 at 5:32

GoogleCodeExporter commented 8 years ago
I echo the higher-priority sentiment already expressed on this issue .. not 
that I think I have the skills to do anything better than a 
sort-of-works-sometimes hack...

Original comment by getAlexD...@gmail.com on 10 Jun 2010 at 5:15

GoogleCodeExporter commented 8 years ago
got any updates on this? I wish to use months on the x-axis label.

Original comment by don.airo...@gmail.com on 26 Jul 2010 at 8:28

GoogleCodeExporter commented 8 years ago
I also think this issue should have higher priority. A plot without axis labels 
is like measurement data without uncertainty, you don't know what you are 
looking at.

Original comment by mbo...@gmail.com on 29 Jul 2010 at 10:47

GoogleCodeExporter commented 8 years ago
Not that I don't want to see nice axis labels - Flot is doing the plotting, but 
you have all kinds of tools from jQuery and plain html/css to create your 
labels yourself...  It sure would be a nice enhancement, but hardly a bug.

Original comment by ma...@mimecom.net on 29 Jul 2010 at 12:24

GoogleCodeExporter commented 8 years ago
@mimecine: this is true, but in terms of ease-of-use and code prettiness, it 
totally makes sense to me to have axis labels taken care of inside flot. I may 
switch to jqplot for just this reason.
higher-priority-plz +1

Original comment by thatn...@gmail.com on 3 Aug 2010 at 7:11

GoogleCodeExporter commented 8 years ago
I find a simple way to add axes is to make a 3x3 table (with zeroed out 
borders) and put the graph in the middle cell. That gives you the surrounding 
cells to make any sort of labels, titles, or explanatory text, and closely link 
them to the graph. (And it makes it easy to position the graph on a page.) 
Sure, it would be nice to have something within flot for axes, but for the 
moment I find that a tables works fine.

Original comment by GT516.U...@gmail.com on 31 Aug 2010 at 3:42

GoogleCodeExporter commented 8 years ago
I would really like to use Flot, but without easy-to use axes labels I will 
have to use something else.  There is limited use to a graph plotting tool, 
which requires a separate tool to control axes labels.

My vote is to raise the priority on this one...

Original comment by lisa.h...@excelscient.com on 31 Aug 2010 at 11:21

GoogleCodeExporter commented 8 years ago
I just started a plugin for axis labels. It currently only supports X and Y 
axis (not X2 or Y2). It supports both types: canvas text or HTML text

http://github.com/xuanluo/flot-axislabels

Original comment by xuan....@engineering.ucla.edu on 4 Sep 2010 at 8:02

GoogleCodeExporter commented 8 years ago
Issue 343 has been merged into this issue.

Original comment by olau%iol...@gtempaccount.com on 13 Dec 2010 at 4:07

GoogleCodeExporter commented 8 years ago
Hi. I created a plugin that allows axis labels by replacing one of the extreme 
(visible min/max) tick label by the axis label. It works for multiple axes and 
has the advantage of not having to mess around with plot sizes and fancy 
positioning. You can get it at 

https://github.com/RuiPereira/flot/raw/axislabels/jquery.flot.axislabels.js

and see a screenshot at

https://github.com/RuiPereira/flot/raw/axislabels/examples/axislabels_flot.png

Original comment by rui.pereira on 31 Mar 2011 at 11:13

GoogleCodeExporter commented 8 years ago
FWIW, Rui Pereira's plugin seems to work pretty well, except it botches the 
centering of Y labels for me.  I used the textAlign property and now it seems 
better.  Unfortunately, the plugin is a bit inefficient, so i hope something 
gets added to the code soon.  My patch attached.

Original comment by lahike...@gmail.com on 4 Nov 2011 at 2:00

Attachments:

GoogleCodeExporter commented 8 years ago
I can confirm last patch solve some annoying axislabel issues i've had ! thanks 
man !

Original comment by mathieuc...@gmail.com on 27 Jan 2012 at 2:49

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Hi. Just to clarify, it seems that the patch on comment #25 refers to xuanluo 
(#22) plugin, not mine. The implementations are quite different.

Original comment by rui.pereira on 27 Jan 2012 at 3:01

GoogleCodeExporter commented 8 years ago
The only full implementation of an axis title/label that I found was the one 
from xuanluo and modification by markrcote 
(https://github.com/markrcote/flot-axislabels), unfortunately it does not work 
for the new multiple axes method in the latest flot version (only does the 
first 2 axes, yaxis and y2axis which does not exist anymore). Anybody else has 
a full plugin for this issue? A chart without axis title/label, especially with 
multiple axes (like on a meteogram) can not really be used.

Original comment by foglia...@gmail.com on 4 Feb 2012 at 9:34

GoogleCodeExporter commented 8 years ago
I fixed up my plugin (https://github.com/markrcote/flot-axislabels) to support 
N axes. I've tested it with Firefox, Chrome, Opera, Safari, IE 9, and IE 8.  
Forcing canvas labels in IE 8 (via axisLabelForceCanvas) does not work at the 
moment, but the default mode (IE transforms + CSS positioning) does.

Original comment by mrcote on 16 Feb 2012 at 10:28

GoogleCodeExporter commented 8 years ago
Great plugin! Could you add plot title as well?

Original comment by remu...@gmail.com on 21 Feb 2012 at 10:34

GoogleCodeExporter commented 8 years ago
Hi,

thanks for this plugin. Unfortunately I can not get the font-family to be 
changed. Can someone tell me how to do this? I tried:
yaxis: { axisLabelForceCanvas: true, axisLabel: 'y-Achse', axisLabelFontFamily: 
'Arial' }

Original comment by kaesebaron on 26 Feb 2012 at 5:44

GoogleCodeExporter commented 8 years ago
Hm I kind of think that plot title is a bit out of scope of this plug-in and 
very easily done with regular HTML/CSS. However, I've gotten this request a few 
times, so I *may* add support for it at some point.

Original comment by mrcote on 12 Mar 2012 at 7:31

GoogleCodeExporter commented 8 years ago
kaesebaron: Sorry, I made a mistake in the README. The option to force canvas 
is axisLabelUseCanvas, not axisLabelForceCanvas. I committed a fix to the 
README.

Original comment by mrcote on 12 Mar 2012 at 7:53

GoogleCodeExporter commented 8 years ago
Thank you.

Original comment by kaesebaron on 23 Mar 2012 at 8:29

GoogleCodeExporter commented 8 years ago
Bit of a shame the plugin by marcrcote is GPL. Any chance of changing the 
license? 

Original comment by tollef.s...@gmail.com on 31 Mar 2012 at 4:11

GoogleCodeExporter commented 8 years ago
Hi all, I have added on to Mark's script for support of Flot 1.1 and the 
updated script can be found at https://github.com/mikeslim7/flot-axislabels. 
Only 1 change has been done on 2 places in the script so the rest of the 
functions are as Mark had made them. :-) Mike.

Original comment by mikeslim7 on 28 Apr 2012 at 9:43

GoogleCodeExporter commented 8 years ago

Original comment by dnsch...@gmail.com on 7 May 2012 at 5:53

GoogleCodeExporter commented 8 years ago
Issue 611 has been merged into this issue.

Original comment by dnsch...@gmail.com on 7 May 2012 at 5:56