Kanaries / pygwalker

PyGWalker: Turn your pandas dataframe into an interactive UI for visual analysis
https://kanaries.net/pygwalker
Apache License 2.0
10.83k stars 549 forks source link

Histogram by percentage (but not by absolute value) #488

Open ibobak opened 4 months ago

ibobak commented 4 months ago

As a data scientist, very often I make many histogram plots by many dimensions. I often compare distributions with each other by looking at side-by-side histograms, but aligning them by percentage - same as https://seaborn.pydata.org/generated/seaborn.histplot.html stat = probability or proportion: normalize such that bar heights sum to 1

But in your case this is problematic: image

ObservedObserver commented 4 months ago

@ibobak thanks for your feedback. I think there are two parts in your current questions.

  1. compare the distribution in different facet.
  2. turn the distribution to percentage.

Currently for comparing distribution, you can set the scale of y axis to be indepent with each other. Here is a tutorial video:

https://github.com/Kanaries/pygwalker/assets/22167673/acf41d8b-629a-4abc-a78d-a712c61f0de4