Commit bb59cb4a authored by Sanjay Yadav's avatar Sanjay Yadav

DOC: Updated documentation for chart.

parent c22fce07
Pipeline #33016 passed with stage
in 1 minute and 10 seconds
......@@ -466,6 +466,47 @@ change:
- `rectangle`: use [CSS](#css) commands instead
- `oval`: use [CSS](#css) commands instead
## Chart
Edits the data inside native pptx charts. `combo` pptx charts are nor supported. `chart` accepts following attributes:-
Note:- All attributes also accepts python expresion or custom function. Such as:-
```yaml
chart:
data:
function: module.functionname
color:
function: module.functionname
....
```
`data`: Pass data to chart.
`x`: Define `x-axis` column name from data.
`size`: This is applicable only for `Bubble Charts`. Column name from data for bubble size.
`color`: Accepts a dictionary (or raw value as well in this case same color code will be get apply for all series) for the series that are being added to the charts. Also provide row level data access to the series using `lambda` function. E.g.:-
```yaml
chart:
color:
function: module.color_function
# In this case you will not have row level access. `color_function` must return a dictionary with keys of series name along with color code value.
# Case 2
chart:
color:
function: "lambda x: module.color_function"
# In this case you will have row level data access. `color_function` will have 3 input parameters
# `handler`, `name`, `value`. `name` will be the series name `value` is the value of a row for the `name` series.
# In this case `color_function` function must return a hex color code, not a dictionary.
```
`stroke`: Same configuration like `color`.
`opacity`: Same configuration like `color`.
## Native charts
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment