Pcolor Error: Matrix Dimensions Must Agree

15 次查看(过去 30 天)
I'm trying to plot the following variables using the pcolor variable:
t1.lat = 100x1
t1.lon = 100x1
t1.u = 100x50
pcolor(t1.lon, t1.lat, t1.u)
Thanks in advance!

回答(1 个)

KSSV
KSSV 2017-11-10
t1.lat = 100x1
t1.lon = 50x1
t1.u = 100x50
pcolor(t1.lon, t1.lat, t1.u)
The above works.
  2 个评论
Duncan Wright
Duncan Wright 2017-11-10
Please could you elaborate ? I don't understand which dimensions need to agree with which ?
KSSV
KSSV 2017-11-10
Say x, y are you are lon and lat.
[X,Y]=meshgrid (x,y);
The dimensions of X,Y and u should be same.

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 NaNs 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by