Sign in to follow this  
natg504

Filtering JSON data by category

Recommended Posts

I'm using a 2D Stacked area chart with a json data source similar to the example below (but with a lot more dates).  I'd like to add a drop-down menu on the page that filters the data by date range.  Any suggestions on the best way to do this?  Thanks,

 

 

{
    "graph": {
        "caption": "My Chart"
    },
    "categories": [
        { "category": [
                {"name": "01/10/2007","showname": "1"},

               .....
                {"name": "10/15/2014","showname": "0"}
            ]
        }
    ],
    "dataset": [
        {
            "seriesname": "First Series",
            "data": [
                {"value": "771569"},

               ...
                {"value": "358887"}
            ]
        },
        {
            "seriesname": "Second Series",
            "data": [
                {"value": "7347"},

               ...
                {"value": "12596"}
            ]
        },
        {
            "seriesname": "Third Series",
            "data": [
                {"value": "40857"},

               ...
                {"value": "0"}
            ]
        }
    ]
}

Edited by natg504

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
Sign in to follow this