villebro commented on issue #10468:
URL: 
https://github.com/apache/incubator-superset/issues/10468#issuecomment-665732577


   @cyang52 I recently thought about precisely what you're describing here. 
Adding an additional multi-select control (`entity` is as good a name as any), 
and then grouping by `groupby + entity` would make it possible to calculate the 
box plot statistics across all `entity` columns. In addition, #10344 that was 
recently merged makes it possible to apply the time grain on any column that is 
used as a grouping variable, making it possible to do the exact same temporal 
box plot as before, if one so wishes.
   
   As box plot is using the legacy plugin framework, you'd need to change the 
control panel in the `superset-ui` repo, more specifically here: 
https://github.com/apache-superset/superset-ui/blob/master/plugins/preset-chart-xy/src/BoxPlot/controlPanel.ts`.
 After that, you'd need to add logic in `viz.py` that makes sure the entity 
columns are added to groupbys and then handled in the pivot operation. It is 
worth mentioning that we're moving away from the legacy plugin architecture, so 
if I were to make major changes to the box plot viz, I'd probably
   
   1) port it to ECharts
   2) make the data request using the new chart data endpoint on 
`/api/v1/chart/data`
   
   Doing it like this you wouldn't need to add anything to `viz.py`, however 
you'd need to do all the necessary pandas transformation work using the 
`post_processing` operations.
   
   If you need help, feel free to reach out on slack. 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to