pcolorm ignores lines of data

2 次查看(过去 30 天)
I try to plot data. Unfortunately, the region is the composition of three single maps. The edges of these maps seem to produce funny effects as can be seen in the figure.
The data set is continuous, but nevertheless by zooming in some data seems to miss.
These plots are produced by using pcolorm(lat,lon,field). Below, the last picture shows the same data set plotted with plotm, to check that the data is existing.
How can i fix this?
I am using matlab 2019a

采纳的回答

Bjorn Gustavsson
Bjorn Gustavsson 2020-8-28
The way I've understood pcolor (which I assume pcolorm is a modification of) makes a colour-patch with corners at [x(n,m),y(n,m)],[x(n+1,m),y(n+1,m)],[x(n+1,m),y(n+1,m+1)] and [x(n,m+1),y(n,m+1)], using the intensity/color from Z(n,m) (this is using shading 'flat'). Sometimes that is an OK behaviour. However when I have some small-sized data that I considere centred at the coordinate-points I have to adjust the input to pcolor to take into account the function's behaviour by repeating the last row and column of the data and modify the [x,y] coordinates by shifting a "half dx and a half dy" and add a last column and row to both. Maybe that's part of your missing-data problem?
HTH
  5 个评论
Bjorn Gustavsson
Bjorn Gustavsson 2020-8-28
Anna, I can imagine that when you try to merge the data you will run into problems with the different data-sets having different sizes? If that's the case you might get somewhere by using scatteredInterpolant - but this would be a bit of a cumbersome detour. Another option might be to use scatterm instead of pcolorm, it might work OK - primarily if you're currently in a "facing a deadline and something gots to work now" situation.
Anna S
Anna S 2020-8-28
Yes, I think the scatterm solution is working best for my problem because the data is not shifted - thank you for that hint!

请先登录,再进行评论。

更多回答(0 个)

类别

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

标签

产品

Community Treasure Hunt

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

Start Hunting!

Translated by