[R] from long/lat to UTM

Gabor Grothendieck ggrothendieck at myway.com
Thu Mar 10 14:52:53 CET 2005


 <Ted.Harding <at> nessie.mcc.ac.uk> writes:
: 
: > yyan liu wrote:
: >> Hi:
: >>   Is there any function in R which can convert the
: >> long/lat to UTM(Universal Transverse Mercator)?
: >>   There are quite a few converters on Internet.
: >> However, the interface is designed as input->output
: >> which I can not convert lots of locations at the same
: >> time.
: >>   Another question is whether there is a function in R
: >> which can tell the time zone from the location's
: >> lat/long?
: >>   Thank you!
: >> 
: >> liu
: 
: On 10-Mar-05 Sander Oom wrote:
: > Hi Yyan,
: > 
: > The proj4R package by Roger Bivand will allow you to project data in 
: > many ways and directions.
: > 
: > http://spatial.nhh.no/R/Devel/proj4R-pkg.pdf
: > 
: > It uses the proj libraries from:
: > 
: > http://www.remotesensing.org/proj/
: > 
: > Not sure where you would derive the time zone!
: > 
: > Good luck,
: > 
: > Sander.
: 
: While there is a longitude-based "nominal" time-zone
: structure (0deg E is the centre of Zone 0 which extends
: for 7.5deg either side; successive time-zones move round
: by 15deg), this does not apply cleanly to the time-shifts
: adopted in different places for local time.
: 
: A World map of regions with different local-time offsets
: is a crazy patchwork, with all sorts of contradictory
: looking regions. For instance, the "-0700" region of
: the USA extends from approx -0830 to approx -0620,
: covering over 2 hours, and parts of "-0800" touch the
: -0700 line and are more than 0100 East of parts of "-0700".
: Even worse can be found over the Indian/Central Asian
: and Malaysian parts of the world, where time-shifts
: of 30 miniutes are also frequent (and, according to my
: Atlas, one country, Nepal, has "5&2/3" i.e. +0540!).
: 
: As Sander says, "Not sure where you would derive the time zone!".
: 
: Unless you can refer a (long,lat) position to a look-up
: table, you can't predict what the zone will be to less
: the 1 hour (except of course for the "nominal" time-zones
: by 15deg sectors). I've never encountered a "digital"
: version of such a table (my Atlas must be based on one,
: though).
: 
: Best wishes,
: Ted.

The fBasics package of the rmetrics project uses the Olsen time
zone data base which does take some of these things into account.




More information about the R-help mailing list