Skip to main content
Legend
August 4, 2014
Question

CF11 CFChartseries Data Attribute

  • August 4, 2014
  • 0 replies
  • 328 views

Has anyone had success in using CF11's new "data" attribute of CFCHARTSERIES?  In particular I'm currently trying to get a pie chart working.  The documentation says:

The chart data. This is an array of arrays.Specify the data as follows: 2,3],[4,5]] or [[3,4,5],[6,7,3]] for charts with z parameter such as bubble chart, or {{[3,4]}} in case of pie charts.


I'm having trouble following what they're trying to say for pie charts.  Inputting what the documentation says, {{[3,4]}}, gives an error.  Using the array of arrays I can only get one pie slice to show or I get multiple charts showing...all with only one piece of data.

The ZingCharts JSON I believe should be something like this but all I get are errors with each variation of this I try:

[

            {

                "values":[11],

                "text":"Item 0"

            },

            {

                "values":[36],

                "text":"Item 1"

            },

            {

                "values":[4],

                "text":"Item 2"

            },

            {

                "values":[59],

                "text":"Item 3"

            }

        ]

This is the result of using [[4],[5]]

This is what I get when using [[4,5,6]]:

Anyone had success with this?

This topic has been closed for replies.