问题
I am using the %chart magic in DataLab to generate charts. I see in the samples that there are options that can be specified in the cell body to fine-tune these charts. Where do I find documentation on these?
回答1:
The charts generated with %chart are using Google's chart tools (https://developers.google.com/chart/). The documentation there describes the options available for each chart. For example, the options for bubble charts are documented at https://developers.google.com/chart/interactive/docs/gallery/bubblechart#configuration-options.
In DataLab, you can specify these options in the cell using either JSON or YAML.
You can get limited help by using %chart --help and %chart <charttype> --help. The help shown there should get much better in a future release.
回答2:
In case anyone remains confused about this an example of the syntax is as follows:
%%chart scatter --data births
title: Birth Weight vs Weeks
height: 400
width: 900
hAxis:
title: Weeks
vAxis:
title: Weight
legend: none
来源:https://stackoverflow.com/questions/33155993/where-can-i-find-more-detailed-documentation-on-what-chart-settings-can-be-used