[R-sig-Geo] read in a csv with readOGR

James Stegen stegen at email.unc.edu
Thu Apr 1 23:19:09 CEST 2010


I am trying to read-in a .csv file that has two columns, one for 
longitude and one for latitude to then overlay on a raster map that I am 
reading in with readGDAL.
I read in the raster as:

test = readGDAL("tmean1.bil")

This seems to work fine.
I then try to read in the csv file as:

coord = readOGR("Lat_Long_105.csv",layer="Lat_Long_105")

, but I get this out

Error in ogrInfo(dsn = dsn, layer = layer, input_field_name_encoding = 
input_field_name_encoding) :
  Multiple # dimensions:

It's unclear to me if I am totally missing the boat when I try to read 
in the csv file. In particular, dsn is also the layer (i.e. there is 
only one file).
Do I need something else for the layer?

Thanks,
James

-- 
James C. Stegen
NSF Postdoctoral Fellow in Bioinformatics
University of North Carolina
Chapel Hill, NC
919-962-8795
stegen at email.unc.edu



More information about the R-sig-Geo mailing list