On 2013-09-28 11:45, John Nicholls wrote:
and with a smaller sized image attached
also here is the format of the original .csv  file

x,y,z1,z2
132073.04,161644.42,-43.00,71.43
132073.01,161644.37,-43.00,71.431
132072.97,161644.32,-42.90,71.432
132072.93,161644.28,-43.00,71.432
132072.90,161644.23,-43.20,71.433
132072.86,161644.18,-43.30,71.433
132072.83,161644.14,-43.40,71.434
132072.79,161644.10,-43.40,71.435
132072.76,161644.05,-43.60,71.435
132072.72,161644.00,-43.60,71.436

Hi,

I am using m.proj on a .csv file  containing magnetic and gps data
(x,y,z1,z2) to convert coordinates from UTM Zone 31N (EPSG 32631) to
Lambert 72 (Belgium), EPSG 31370.

GRASS 6.4.3RC3 (2013) Ubuntu Release 12.04 (precise) 32-bit.
The input data file contains X and Y coordinates in UTM Zone 31N, with
columns z1 for magnetic readings, and z2 for elevation.
Grass Location 13009 created using EPSG code 32631


You could re-project with ogr2ogr and see if this helps. Let's say your data file is "original.csv" with the columns as given above. Then you'd need a .vrt file like this one:

$ cat original.vrt
<OGRVRTDataSource>
    <OGRVRTLayer name="original">
        <SrcDataSource>original.csv</SrcDataSource>
        <GeometryType>wkbPoint</GeometryType>
        <LayerSRS>EPSG:32631</LayerSRS>
        <GeometryField encoding="PointFromColumns" x="x" y="y"/>
    </OGRVRTLayer>
</OGRVRTDataSource>

... and use ogr2ogr like this:

$ ogr2ogr reprojected.shp original.vrt -t_srs EPSG:31370

My debug output tells me that this transformation has been carried out (which looks pretty much like what you mentioned).

OGRCT: Source: +proj=utm +zone=31 +datum=WGS84 +units=m +no_defs

OGRCT: Target: +proj=lcc +lat_1=51.16666723333333 +lat_2=49.8333339 +lat_0=90 +lon_0=4.367486666666666 +x_0=150000.013 +y_0=5400088.438 +ellps=intl +towgs84=-106.869,52.2978,-103.724,0.3366,-0.457,1.8422,-1.2747 +units=m +no_defs

_______________________________________________
grass-user mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-user

Reply via email to