units
parameter controls the units (metres m
or kilometres
km
) in which the coordinates should be returned.
gridCoords(grid = NULL, units = c("km", "m"))
gridRef
gridCoords("NZ1265") # returns x=412, y=565 (in km)
gridCoords("NZ123654", units="m") # returns x=412300, y=565400 (in m)
Run the code above in your browser using DataLab