You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I saw #17 explaining how to use kind="values and x_range in order to use aggregated data, but I'm finding it hard to combine this functionality with setting a specific column for output.
I've got a dataset with a set of locations (lat & long) with measurements taken at each point giving a numerical value.
lat long val
001.012 001.01 11
001.431 004.49 25
001.769 008.72 04
002.100 001.32 03
002.504 003.49 17
...
(rubbish formatting but it gives you the right idea)
I've binned the y-values (lat) using pd.cut to give a lat_bins column and plotted this using:
This displays a plot without any data; and no error appears when running the code so I don't know what to fix. The goal is to have a plot at each latitude showing the distribution according to longitude. (i.e., the dataset shown above would have the first layer showing 11 - 25 - 4 going across from 001 to 008 lat.
The text was updated successfully, but these errors were encountered:
Hi! Not sure I fully understood what you want to obtain here.
One thing I can say, though, is that kind="values" is not meant to be used with "by" - it's meant to be used only if you want to do all the binning yourself (and no smoothing will be done by joypy).
So you would need to have a dataframe with lat_bins as rows, and lon_bins as columns, with the grouped val in the cells. Does it make sense?
Example with iris (just renamed the columns to be similar to your case):
Hi,
I saw #17 explaining how to use
kind="values
andx_range
in order to use aggregated data, but I'm finding it hard to combine this functionality with setting a specific column for output.I've got a dataset with a set of locations (lat & long) with measurements taken at each point giving a numerical value.
(rubbish formatting but it gives you the right idea)
I've binned the y-values (lat) using
pd.cut
to give a lat_bins column and plotted this using:fig, axes = jp.joyplot(df, by="lat_bins", column="long")
But what I'd like to have is something like:
fig, axes = jp.joyplot(df, by="lat_bins", column="long", kind="values", x_range=<some range>))
This displays a plot without any data; and no error appears when running the code so I don't know what to fix. The goal is to have a plot at each latitude showing the distribution according to longitude. (i.e., the dataset shown above would have the first layer showing 11 - 25 - 4 going across from 001 to 008 lat.
The text was updated successfully, but these errors were encountered: