Similar question to this one.
I have a 10x10 grid of Z vs (X,Y) values from which I would like to make a surface plot. But surf(X,Y,Z) creates a 9x9 grid with colors based on (I guess) values at vertices or edges. Is there an alternative way to make a 10x10 color grid with colors being a function of Z(i,j) only?

 採用された回答

Walter Roberson
Walter Roberson 2022 年 5 月 3 日

1 投票

warp()

2 件のコメント

Mariano Garcia
Mariano Garcia 2022 年 5 月 3 日
OK thanks. Good to know, but might there be any options that work in MATLAB R2014b without image processing toolbox?
Walter Roberson
Walter Roberson 2022 年 5 月 4 日
surf() can be used to do texture mapping. You supply the X and Y locations, the Z is the height, and you pass in 'CData' with the color to be painted. You have to set CDataMappingMode and if I recall correctly, 'FaceColor', 'interp'

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

製品

リリース

R2014b

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by