broken country borders in map_continents [message #29258] |
Fri, 08 February 2002 05:14  |
sso
Messages: 13 Registered: February 2002
|
Junior Member |
|
|
Hi,
when using "map_continents,/countries" , some of the country borders
get broken. On the projection I use it seems almost as (parts of) the
Ottoman Empire has returned...
These are the commands I use:
map_set, 60, -180, -180, /stereo, /cont, $
limit = [30, -180, 90, 180], $
latdel = 5, londel = 10, charsize = 1.6
map_continents, fill_cont = 1
map_continents, /countries
Does any have any explanations/help??
Sverre Solberg
Norwegian institute for Air Research
|
|
|
Re: broken country borders in map_continents [message #29377 is a reply to message #29258] |
Mon, 18 February 2002 10:57  |
Kelly Dean
Messages: 92 Registered: March 1997
|
Member |
|
|
The northern border of Turkey is the Black Sea. You need to add another
call to MAP_CONTINENTS with the keyword /Coast to get the Black Sea and
Caspian Sea to finish off the boundries.
However, many of the political boundries in IDL's database are still out
of date, especially in the Middle East. My solution was to use the new
Shapefile read routines in IDL and get the updated shapefiles of the
region from ESRI.
Kelly Dean
CSU/CIRA
Sverre Solberg wrote:
> Hi,
>
> when using "map_continents,/countries" , some of the country borders
> get broken. On the projection I use it seems almost as (parts of) the
> Ottoman Empire has returned...
>
> These are the commands I use:
>
> map_set, 60, -180, -180, /stereo, /cont, $
> limit = [30, -180, 90, 180], $
> latdel = 5, londel = 10, charsize = 1.6
>
> map_continents, fill_cont = 1
> map_continents, /countries
>
> Does any have any explanations/help??
>
> Sverre Solberg
> Norwegian institute for Air Research
|
|
|
Re: broken country borders in map_continents [message #29384 is a reply to message #29258] |
Mon, 18 February 2002 07:23  |
Liam E. Gumley
Messages: 378 Registered: January 2000
|
Senior Member |
|
|
Sverre Solberg wrote:
[stuff deleted]
> the HiRes keyword has no effect. Neither does it help to change map
> projection or idl version. The northern border of Turkey as well as
> other country borders in that area are missing. Seems I cant solve
> this (but cant be the only one complaing about this?)
Have you tried the USGS coastline extractor?
http://rimmer.ngdc.noaa.gov/coast/getcoast.html
Try the following option "WVS and all Political Boundaries" and "Mapgen"
output. Here's a quick and dirty IDL routine for plotting the resulting
data on a map, e.g.
IDL> plotwvs, '1364.dat'
The procedure also accepts all keywords accepted by PLOTS.
PRO PLOTWVS, FILE, MAXREC=MAXREC, _EXTRA=_EXTRA
;- Check arguments
if (n_elements(file) eq 0) then $
message, 'Argument FILE is undefined'
if (n_elements(maxrec) eq 0) then $
maxrec = 100000L
;- Create segment arrays
lon = fltarr(maxrec)
lat = fltarr(maxrec)
;- Open the file
openr, lun, file, /get_lun
;- Loop until end of file is reached
num = 0L
while (eof(lun) ne 1) do begin
;- Read a record
record = ' '
readf, lun, record, format='(a)'
;- Check for header record
if (strmid(record, 0, 1) eq '#') then begin
;- Plot data for this segment
if (num gt 1) then $
plots, lon[0:num-1], lat[0:num-1], _extra=_extra
;- Reset counter for this segment
num = 0L
endif else begin
;- Extract lon/lat from this record
reads, record, this_lon, this_lat
lon[num] = this_lon
lat[num] = this_lat
num = num + 1L
endelse
endwhile
;- Close the file
free_lun, lun
END
Cheers,
Liam.
Practical IDL Programming
http://www.gumley.com/
|
|
|