Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pie chart plot type added to TablePlotter #330

Merged
merged 9 commits into from
Oct 22, 2020
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ shipped plugins install themselves through the `webviz_config_plugins` entrypoin
ad-hoc plugins as this is costly to maintain. Also, the `module.PluginName` notation in
configuration files can then in future be used fo distinguish between multiple plugin
packages using the same plugin name.
- [#330](https://github.com/equinor/webviz-config/pull/330) - Pie chart plot type now
available in table plotter.

### Fixed
- [#325](https://github.com/equinor/webviz-config/pull/325) - Support plugin projects
Expand Down
13 changes: 13 additions & 0 deletions webviz_config/generic_plugins/_table_plotter.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ def plots(self) -> dict:
"histnorm",
],
"bar": ["x", "y", "color", "facet_col", "barmode"],
"pie": ["values", "names"],
"scatter_3d": ["x", "y", "z", "size", "color"],
"line": ["x", "y", "color", "line_group", "facet_col"],
"line_3d": ["x", "y", "z", "color"],
Expand Down Expand Up @@ -130,6 +131,18 @@ def plot_args(self) -> dict:
"multi": False,
"clearable": False,
},
"values": {
"options": self.numeric_columns,
"value": self.plot_options.get("values", self.numeric_columns[0]),
"multi": False,
"clearable": True,
},
"names": {
"options": self.columns,
"value": self.plot_options.get("names", None),
"multi": False,
"clearable": True,
},
"size": {
"options": self.numeric_columns,
"value": self.plot_options.get("size", None),
Expand Down