Clear Filters
Clear Filters

empty plotting using contourf

9 views (last 30 days)
Yu Li
Yu Li on 17 Dec 2017
Edited: Yu Li on 22 Nov 2018
Hi: I have a data set of X,Y,Z, which corresponds to x,y axis, and paremeter need to be plotted
but when I use [xc,yc]=contourf(X,Y,Z),
the plotting is blank, could anyone help me about this
Thanks!
Li

Accepted Answer

Star Strider
Star Strider on 17 Dec 2017
Your data throws this error when I try to plot it with contourf:
Warning: Contour not rendered for constant ZData
> In contourf (line 60)
You will have to solve that problem.
Exploring this, the mean (using nanmean) of ‘Z’ is 6, and standard deviation (using nanstd) is 0.
This is the best you can hope for:
figure(1)
contourf(X, Y, Z, [6 6])
grid on
  2 Comments
Yu Li
Yu Li on 17 Dec 2017
thank you so much!
Star Strider
Star Strider on 17 Dec 2017
As always, my pleasure!

Sign in to comment.

More Answers (0)

Categories

Find more on Contour Plots in Help Center and File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!