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'm trying to make a 2D color plot of my low temperature transport measurement. The data were taken and saved in a series of .dat files. The data looks something like this:
B (T), T(K) , V (V), I (A)
0, 4.01, -10.0, 0.001
0, 4.02, -9.9, 0.001 ...
Each file was taken at a specific magnetic field. (0 to 2 Telsa with 0.2T step) in total 11 files. I imported all the files and concatenate them into a single pandas dataframe which looks like this:
B
T
V
I
0
4.01
-10.0
0.001
0
4.02
-10.0
0.001
...
...
...
...
0.2
4.01
-10.0
0.001
0.2
4.02
-10.0
0.001
...
...
...
...
0.4
4.01
-10.0
0.001
0.4
4.02
-10.0
0.001
...
...
...
...
Now I want to make a 2D color plot with V and B as the x and y axis and I as z (color). How do I do that with Holoview.Image?
I know it can be done using using seaborn heatmap but I want to use holoview for interactive plot and other functionalities. It also works with Holoviews.HeatMap, but HeatMap has a few problems. HeatMap axes are categorical not numerical, which makes it difficult and non-intuitive to set xticks, xlim, etc.
Holoviews.Image is more suitable for my data, but it accepts only gridded data, not columnar data like pandas dataframe.
I guess, in a nutshell, my question is how to convert pandas dataframe to gridded data in order to plot in Holoviews.Image element.
The text was updated successfully, but these errors were encountered:
I posted this questions on StackOverflow as well: https://stackoverflow.com/questions/55962945/plot-holoviews-image-using-pandas-dataframe
I'm trying to make a 2D color plot of my low temperature transport measurement. The data were taken and saved in a series of .dat files. The data looks something like this:
B (T), T(K) , V (V), I (A)
0, 4.01, -10.0, 0.001
0, 4.02, -9.9, 0.001 ...
Each file was taken at a specific magnetic field. (0 to 2 Telsa with 0.2T step) in total 11 files. I imported all the files and concatenate them into a single pandas dataframe which looks like this:
Now I want to make a 2D color plot with V and B as the x and y axis and I as z (color). How do I do that with Holoview.Image?
I know it can be done using using seaborn heatmap but I want to use holoview for interactive plot and other functionalities. It also works with Holoviews.HeatMap, but HeatMap has a few problems. HeatMap axes are categorical not numerical, which makes it difficult and non-intuitive to set xticks, xlim, etc.
Holoviews.Image is more suitable for my data, but it accepts only gridded data, not columnar data like pandas dataframe.
I guess, in a nutshell, my question is how to convert pandas dataframe to gridded data in order to plot in Holoviews.Image element.
The text was updated successfully, but these errors were encountered: