0

I'm trying to plot a 3D contour plot with echarts4r and it's doesn't show anything, even if it doesn't give any error. I've tried to use also plot_ly and I had the same result.

Here is the picture of the result with echarts.

enter image description here

And here is the code i used:

lower_df %>% 
  e_charts(x) %>% 
  # e_scatter_3d(y, DKQ) %>%
  e_surface(y, DKQ, wireframe = list(show = FALSE)) %>%  
  e_visual_map(DKQ)

The only thing that seems weird is that x values are on the range (-45, -50) and DKQ values are in the range (0.8, 0.95), hence I would have expected the axes had a tighter range compared with what you see in the picture.

Any advice or solutions would be very helpful for me. Thanks!

Luca
  • 49
  • 6
  • You maximise your chance of getting a useful answer if you provide a minimal reproducible example. This includes your data! [This post](https://stackoverflow.com/help/minimal-reproducible-example) may help. Where do you specify your `z` values in your code? – Limey Feb 18 '22 at 15:21
  • Unfortunately i can't share data. Even if I use z = DKQ the code doesn't work properly, but if I run e_scatter_3d() instead of e_surface() the same data shows a proper graph – Luca Feb 18 '22 at 15:35
  • You're not the first person to say that. Try to repeat the problem with a widely available dataset: `diamonds` or `mtcars` for example. – Limey Feb 18 '22 at 15:40
  • with mtcars and diamonds seems to work or at least something was show in the plot. – Luca Feb 18 '22 at 15:53
  • ...which suggests it's a feature of your data. Which you can't share. Which means it's going to be difficult to help you. Best of luck... – Limey Feb 18 '22 at 16:04
  • I found that the problem was that there weren't enough rows in the dataset. Thanks for the help! – Luca Feb 21 '22 at 08:46

0 Answers0