[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
m_map and GNU Octave for map projection aka sphere mapping
From: |
Eric Chassande-Mottin |
Subject: |
m_map and GNU Octave for map projection aka sphere mapping |
Date: |
Tue, 19 Feb 2008 19:11:14 +0100 |
[resent because of an oversized attachment]
I have tried to use the package m_map to make
map projection which you can get here:
http://www.eos.ubc.ca/~rich/map.html
See the site to get an idea of the types
of available mappings. Those include Mollweide
which I wanted.
I have tested some of the
demos scripts and the package works
pretty much "out of the box" with octave 3.0
and gnuplot 4.2. I give below a script that generates
the Mollweide map of some function.
the resulting plot looks good but it would be useful that
"educated" users checks that it indeed makes
sense.
as far as I have seen, map projection is a missing
feature of GNU Octave. so this is good news.
eric.
===============================
addpath("private"); # access private functions
clear;
N=128;
Plat=linspace(-90,90,N);
Plon=linspace(-180,180,N);
[Plg,Plt]=meshgrid(Plat,Plon);
m_proj('mollweide','longitude',[-180 180]);
P=sin(2*pi/180*Plg).*cos(2*pi/180*Plt);
clf;
m_pcolor(Plg,Plt,P);
shading("flat");
colorbar("SouthOutside");
axis("off");
demo.png
Description: PNG image
- m_map and GNU Octave for map projection aka sphere mapping,
Eric Chassande-Mottin <=