Welcome Guest Search | Active Topics |

How to display the headers are not the left, and put them on the bar top + one more bonus question?
skystar
#1 Posted : Saturday, October 25, 2014 5:10:45 PM(UTC)
Rank: Newbie

Groups: Registered
Joined: 10/17/2014(UTC)
Posts: 6

Thanks: 0 times
Was thanked: 0 time(s) in 0 post(s)
Good day dear colleagues.
Prompt, can not display the title bars on the left, just above?
Here is my code:

Code:
$('header').jqChart({
                title: { text: title],
                    fillStyle: '#85b1de'
                },
                legend: { visible: false },
                border: { visible: false },
                axes: [
                    {
                        strokeStyle: 'transparent',
                        visible: false,
                        majorGridLines: { visible: false },
                        lineWidth: 0,
                        location: 'bottom',
                        majorTickMarks: { visible: false },
                        labels: {
                            visible : false
                        }
                    },
                    {
                        strokeStyle: 'black',
                        visible: false,
                        majorGridLines: { visible: false },
                        lineWidth: 0,
                        location: 'left',
                        majorTickMarks: { visible: false },
                        labels: {
                            visible : true,
                            fillStyle: '#85b1de',
                            font: '16px sans-serif'
                        }
                    }
                ],
                animation: { duration: 0.5 },
                series: [
                    {
                        pointWidth: 0.5,
                        type: 'bar',
                        fillStyles: color,
                        data: [
                            [label[0], data['a']],
                            [label[1], data['b']],
                            [label[2], data['c']],
                            [label[3], data['d']]
                        ],
                        labels: {
                            stringFormat: ' %s %%',
                            valueType: 'dataValue',
                            font: '14px sans-serif',
                            fillStyle: 'white'
                        }
                    }
                ]
            });


As the image:



And the last question, I need to make sure that when clicking on the the bar, it was possible to increase or decrease its value. Is that possible? If yes, how to implement it? Thank you all!
Dragan
#2 Posted : Monday, October 27, 2014 1:38:36 PM(UTC)
Rank: Advanced Member

Groups: Administrators, DataVizJavaScript, jQueryChart, jQueryDV, MvcChart, Registered
Joined: 1/3/2011(UTC)
Posts: 483

Thanks: 0 times
Was thanked: 87 time(s) in 87 post(s)
Hi,

Currently, you can put the labels inside the chart area, but they won't be exactly that you want:

Code:
{
                        strokeStyle: 'black',
                        visible: false,
                        majorGridLines: { visible: false },
                        lineWidth: 0,
                        location: 'left',
                        majorTickMarks: { visible: false },
                        labels: {
                            position: 'inside',
                            vAlign : 'top',
                            visible: true,
                            fillStyle: '#85b1de',
                            font: '16px sans-serif'
                        }
                    }


Here is an example how you can handle the data point click:
http://www.jqchart.com/jquery/chart/ChartFeatures/Hyperlinks

Here is an example how you can change chart data:
http://www.jqchart.com/jquery/chart/RealTime/ChartDataPoints
Best Regards,
Dragan Matek
jqChart Inc.
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

FlatEarth Theme by Jaben Cargman (Tiny Gecko)
Powered by YAF 1.9.4 | YAF © 2003-2010, Yet Another Forum.NET
This page was generated in 0.404 seconds.