dan pfx

automatic resize multi series charts when hiding serie by clicking on label

Recommended Posts

Hello,

 

I don't know if this is already possible, but I would like that, when a user click on a label of a multi series (multi line for example) chart to hide one line, the chart redraw to take maximum size for visible lines.

 

This is particularly useful when a chart have 10 lines, and when 9 lines are goes from 5 to 10 on Y axis, and 1 line goes from 1000 to 1500 on Y axis... chart can't be read even if you hide the 1000 to 1500 line, all other lines are at bottom of chart.

 

Thank you,

Dan

Share this post


Link to post
Share on other sites
Hi,

 

It seems that you want to re-scale your y-axis when you click on a legend to hide the corresponding dataset series. It is not possible to scale Y-axis when a dataset is hidden by clicking on legend, as of now. However, as a workaround, you may use "LegendItemClicked" event to scale y-axis when a dataset is hidden by clicking on legend. 

 

Please find an attached sample created using this workaround.

 

Hope this helps.

Rescaling yAxis Demo.zip

Share this post


Link to post
Share on other sites

Hello,

 

Is there any update on this one?

Are there any plans to support this feature?

 

 

The proposed walk-around does the work, but doesn't scale well (when having a lot of series). However it did inspire me to come up with similar solution - As using the angular+ngrx, it can get quite easy to just prune out the data for the 'switched off' series entity (on legend events). 

 

Still, I'm interested if this feature planned to be implemented?

Share this post


Link to post
Share on other sites

Hello,


Thanks for the query.
 
Your requirement is achievable by setting transposeAxis attribute as 1 at chart attribute level.
 
If you hide a dataset using legend icon, the transposeAxis attribute (when set to 1) will compute the axes limit with respect to maximum and minimum value of the visible dataset(s). 
 
Kindly refer the sample fiddle below for the implementattion.
 
Please feel free to revert back to us for further assistance.

Share this post


Link to post
Share on other sites

Hi Prerana

I've the same problem, more series of data and the need to rescale chart on Y axis after than the user has hidden the unuseful series (we can't do this previusly because we can't know what hide exactly).

I'm using the zoomline chart under IBM Rational Developer for i 9.5.  Ver 3.9.0 (charts in my edition).

The example in zip file one time downloaded is empty (0 bytes), is possibile restore it for download? Also the fiddle chart is unavailable.

Do you can help in some way?

Thanks for help!

 

Share this post


Link to post
Share on other sites

Perhaps a mistake but sample chart doesn't work... at this moment

This part seems to be a mistake, property of the chart are mixed with category items,  but also removing it it doesn't render.

Can you show me something of working?

    {
                    "category": [
                        { "label": "Mon" }, 
                        { "label": "Tue" }, 
                        { "label": "Wed" },
                        {
                            "vline": "true",
                            "lineposition": "0",
                            "color": "#6baa01",
                            "labelHAlign": "center",
                            "labelPosition": "0",
                            "label": "National holiday",
                            "dashed":"1"
                        },
                        { "label": "Thu" }, 
                        { "label": "Fri" }, 
                        { "label": "Sat" }, 
                        { "label": "Sun" }

Share this post


Link to post
Share on other sites

Hi Frank,

 

Yes, the provided sample works, you need to hit the jsfiddle link shared using "http" explicitly and it would work. As the JS file cdn links are using "http".

 

However, to avoid confusion check the below sample fiddle with the recent version 3.14.1 with all cdn links using https.

http://jsfiddle.net/jzcfuo5t/

 

Thanks,

Akash.

Share this post


Link to post
Share on other sites

Hi

I am  also trying to do the same  as Frank wants and  the answer  is satisfactory   and working fine for fusioncharts  @version 3.16.0  and not working  for  @version 3.8.0  .    Can any one  help me how transposeAxis  can  be supported  in  @version 3.8.0     and what is the minimum version onwards it supports  transposeAxis  .  I want the best way to do so .

 

My application using  Angular v1.5.11 and fusioncharts @version 3.8.0 . 

 

Regards,

Pawan

 

 

Edited by Pawan

Share this post


Link to post
Share on other sites
4 minutes ago, Pawan said:

Hi

I am  also trying to do the same  as Frank wants and  the answer  is satisfactory   and working fine for fusioncharts  @version 3.16.0  and not working  for  @version 3.8.0  .    Can any one  help me how transposeAxis  can  be supported  in  @version 3.8.0     and what is the minimum version onwards it supports  transposeAxis  .  I want the best way to do so .

 

My application using  Angular v1.5.11 and fusioncharts @version 3.8.0 . 

 

Regards,

Pawan

 

 

@Pawan transposeAxis feature is supported from 3.11.0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now