geotiff plot on lat-lon axes

37 ビュー (過去 30 日間)
Adrienne Marshall
Adrienne Marshall 2015 年 12 月 8 日
コメント済み: BN 2020 年 4 月 13 日
Hi all,
I'm trying to plot data from a geotiff file onto lat-lon axes. Seems like it should be easy, but I keep getting error messages and can't understand why. Any advice much appreciated! My code:
% read the data
[june_swe,R] = geotiffread('snwe_flx_ccsm3a2bcsd_20100531.tif');
% plot the data
figure
mapshow(june_swe, R)
Error message:
Error using mapshow Expected input number 1, I or X or RGB, to be one of these types:
uint8, uint16, double, logical
Instead its type was single.
Error in validateMapRasterData>parseImageInputs (line 108) validateattributes(A, {'uint8', 'uint16', 'double', 'logical'}, ...
Error in validateMapRasterData>validateImageComponent (line 92) [A, R] = parseImageInputs(mapfcnname, dataArgs{:}, cmap, rules );
Error in validateMapRasterData (line 26) [Z, SpatialRef] = validateImageComponent(mapfcnname, ...
Error in maprastershow (line 126) [Z, SpatialRef, displayType, HGpairs] = ...
Error in mapshow (line 228) h = showFcn(varargin{:});
  1 件のコメント
BN
BN 2020 年 4 月 13 日
Do you found the solution? I have a same issue!

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

回答 (1 件)

Vaibhav Awale
Vaibhav Awale 2016 年 1 月 14 日

カテゴリ

Help Center および File ExchangeGraphics Object Identification についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by