[R-sig-Geo] convert long/lati to UTM
Paul Hiemstra
p.hiemstra at geo.uu.nl
Thu Jul 9 22:23:37 CEST 2009
Hi,
More in general you need to take a look at the sp-pacakge for Spatial
classes in R. Once your data is in these classes you can use spTransform
from the rgdal pacakge to perform the projection. spTransform uses the
proj4 library. You need to find the so called proj4 strings describing
both the source and target projection.
cheers,
Paul
Steve Hong schreef:
> Hi R-sig-geo list,
>
> I am very new to spatial stat using R. I have a basic (pretty much to most of you) question. I have data set with "Longitude" and "Latitude" columns and want to convert to them "UTM" Although I found example of it from the previous questions and answers, I am still struggling to handle the task. Can anyone give me step by step guide as detailed as possible? I copied and pasted partial data below.
>
>
>> df
>>
> Latitude Longitude V1 V2 V3 V4 V5
> 1 44.93342 -91.26773 5.633098 5.768218 5.455419 0.000000 3.797475
> 2 45.26847 -91.00759 5.571924 5.236741 0.000000 3.797475 4.450634
> 3 45.42214 -91.09543 5.994687 5.517567 0.000000 4.775137 5.589799
> 4 45.41381 -91.68441 6.066919 5.460165 0.000000 3.496515 5.793042
> 5 45.39483 -91.96903 6.089662 5.663694 4.726833 4.496390 5.553282
> 6 45.30666 -92.33407 5.252253 5.087444 3.496515 4.098471 4.838805
> 7 45.81549 -92.08828 5.967668 5.309292 0.000000 0.000000 4.098471
> 8 45.42060 -92.25039 5.645596 5.309292 0.000000 0.000000 4.700505
> 9 45.13453 -91.51800 5.838799 5.464860 0.000000 4.838805 5.613648
> 10 43.94975 -88.07627 5.812347 5.703203 4.672477 3.797475 4.450634
>
> Thank you very much in advance!!!
>
> Steve
>
> _______________________________________________
> R-sig-Geo mailing list
> R-sig-Geo at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
>
More information about the R-sig-Geo
mailing list