Plotting image over map

16 views (last 30 days)
Trevor Harris
Trevor Harris on 2 Feb 2017
Answered: Kelly Kearney on 2 Feb 2017
Hey everyone,
I have a few maps as images that I'd like to plot a ships gps track ontop of. I've attached such a map. Does anyone have any suggestions on how I first anchor this to a GPS coordinate? I'm currently plotting via image(imread('test.png')) which means I have number of pixels on the x and y axis.
I'm not asking anyone to do this for me, I am fairly competent in Matlab, I just need to be pointed in the right direction. FYI: I do have the mapping toolbox.
Thanks! Trevor

Answers (1)

Kelly Kearney
Kelly Kearney on 2 Feb 2017
You'll need to georeference the image. You might be able to do this automatically on import if the image already has that info attached to it (e.g. geotiffread). Otherwise, the Mapping Toolbox provides a few different functions for this, such as georefcells. Once you have a reference vector or reference matrix for your image, you can plot it to a map axis using geoshow, pcolorm, etc.

Community Treasure Hunt

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

Start Hunting!