On this page

The important information that every script chart developer should know is that a Scripted Chart has 2 parts:

  1. script that is responsible for collecting data and preparing it for display
  2. a Javascript layout

We will explain both parts with examples, but keep in mind, that programming skills are required in order to be able to develop your own custom script charts.

Data script

The script will be written in Groovy language (or Java) and is responsible for collecting the data and formatting/grouping it as needed in the chart.

Our xChart API provides some helper classes for creating the scripts.

What the chart needs to return, is a JSON Object (chart data), which will be the input for the javascript layout. You can return our ready-to-use ChartData Object or just return a String that contains a valid JSON. This JSON value will be available as the param chart data in the JavaScript script.

Parameters are available as Variables. To get the variable name of a parameter you can just click on the name and the variable will be inserted in the script where at the point of the cursor.

Javascript layout

The layouts are created with the help of the c3.js library. Following the documentation on their website, you can create your own layouts.



If you still have questions, feel free to refer to our support team.