Hi,
To give an idea of what I am trying to achieve. I will explain how my checkboxes are shown now.
The first three check boxes are constant (always displayed on the menu).
Other check boxes are shown on menu based on 'A' or 'B' is passed from json.
If user receives "A", two more check boxes are added (shown on the menu). (eg: Apple, Banana)
If user receives "B", only one check box is added (eg: Carrot) along with existing three constant check boxes.
So based on the number of checkboxes shown at any point of time, I want the series as well to be dynamic.
Example:
For 'A' - 5 checkboxes are shown, I should be able to create five charts by checking all of them (so two more series need to be added here dynamically).
For 'B' - 4 checkboxes are shown, I should be able to create four charts by checking all of them (so only one more series need to be added dynamically).
Data for all newly added charts are different from each other.
So, how can I add or remove series dynamically based on 'A or 'B' passed.
Fiddle: https://jsfiddle.net/ozctfbsL/23/