[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Plot a map of Europe

From: PhilipNienhuis
Subject: RE: Plot a map of Europe
Date: Tue, 10 Nov 2015 11:13:35 -0800 (PST)

Jorgen Sandberg wrote
> Dear Mr Potorti,
> Thank you for the mail.
> I am trying to make M_Map work with Octave, but I am facing some
> incompatibilities like "verLessThan" can't be found.
> Do you know of a way to plot a map of Europe that works with Octave?
> Regards,
> Jorgen Sandberg
> -----Original Message-----
> From: Francesco Potortì [mailto:

> address@hidden

> ] 
> Sent: 10 November 2015 17:21
> To: Jorgen Sandberg <

> jorgen@

> >
> Cc: 

> help@

> Subject: Re: Plot a map of Europe
>>I have searched the internet, but not found a real "how to" instruction 
>>on how to plot a map of for example Europe and add a contour on top. I 
>>need to know the packages to install and where I can find map data in a 
>>format accepted by OCTAVE. I really needs an idiots guide to plotting 
>>maps in OCTAVE.
> Generally speaking, you can draw a plot on top of any background image.
> The general way to do so is something like
>     map = imread(mapfile);
>     image(map);
>     axis('image', 'off', 'nolabel');
>     hold on
>     plot(x, y);
> x and y should use the same measure of unit as the map, that is, pixels.

As of recently there's a new OF mapping package release for Octave that
contains ArcGIS shaperead, shapedraw and geoshow / mapshow functions. 
They're still a bit experimental, esp. geoshow / mapshow, but you give it a
try.  And I'd love to get feedback on them (on the bug tracker of patch

To get it:

pkg install -forge mapping
pkg load mapping

If you can uncover a map of Europe in .shp format [1] (you'll probably need
the .shp .idx .dbf files but just .shp will do as well) you can then simply
read and plot them:

shp = shaperead (<.shp filename in quotes>);
shapedraw (shp)

or simply (less efficiënt as the map must be read each time):

shapedraw (<.shp filename between quotes>)

The commands

help shaperead
help shapedraw

give info on how to call those functions.


[1] google for "europe shape map"to get e.g.,:    (but
maybe too complicated)

View this message in context:
Sent from the Octave - General mailing list archive at

reply via email to

[Prev in Thread] Current Thread [Next in Thread]