mapprofile used on a projected map

I am trying to get a data profile along an image band in projection UTM and datum WGS84. I am surprised that mapprofile does not work on a projected image. I'll be grateful to know about alternatives to use. Reprojecting to Geographical coordinates is rather time-consuming. Thanks! BM

Answers (1)

Chad Greene
Chad Greene on 8 Feb 2017
If you have a 2D projected map and its corresponding x,y coordinates, you can use interp2 to interpolate along any path you wish. You can create a straight-line path using linspace to make x and y (or lat and lon) arrays from the starting point to the ending point.
If your map is a geotiff, you can use geotiffinterp.

6 Comments

Dear Chad, thank you very much for your answer. Actually, I don't think interp2 or geotiffinterp are the commands I'm looking for. Below is an illustration of what I'd like to do. This is straightforward using mapprofile, only if the image is in Lat/Long, but not in UTM. Strange... I guess I'm missing something. BM </matlabcentral/answers/uploaded_files/69411/Capture.PNG>
BM-the image didn't get uploaded.
I think it is uploaded now. BM
This is like pulling teeth. Exactly what information do you have? Do you have the x and y or lat and lon coordinates of the radiance map? Do you have x and y or lat and lon coordinates of the transect?
Hi Chad, The images are in X,Y (UTM projection). The transect is a shape file also in UTM. Everything would be easy if the data was in Lat/Long, but it seems there are not equivalent commands for projected data (?). Strange, specially when huge amounts of Landsat data are distributed in UTM. I now I could "unproject" images to Lat/Long, but that's computationally quite inefficient, and a bit too much for my PC. I'm really looking forward for suggestions/assistance on this. Thanks! BM

Sign in to comment.

Asked:

BM
on 8 Feb 2017

Commented:

BM
on 22 Feb 2017

Community Treasure Hunt

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

Start Hunting!