Hi all

My colleague, a physical oceanographer, and I are having problems getting his geographic layers into the correct projection (after importing as a netcdf file), and we are hoping someone can help us. We are using the Raster package.

My colleague obtains a Dutch Rijksdriehoek in the first instance but then rotates this by 17 degrees to run his models. He then provides me with a netcdf file where the layers are still projected at 17 degrees from the normal Rijksdriehoek.

Is there a way in R to rotate the layers back from the 17 degrees? 

If anyone can help we would greatly appreciate it!

Thanks

Tanya and Matias



R Code 
# Load the packages:
library("sp")
library("ncdf4")
library(raster)

# get the netcdf and read in to R
d <- raster("test_layers.nc", varname = "time_exp") 

# rijksdriehoek projection
RD <-CRS("+proj=sterea +lat_0=52.15616055555555 +lon_0=5.38763888888889 +k=0.9999079 +x_0=155000 +y_0=463000 +ellps=bessel +units=m +no_defs") ##http://spatialreference.org/ref/epsg/28992/proj4/,  

# reproject to Rijksdriehoek
pr1 <- projectRaster(d, crs=newproj)
	[[alternative HTML version deleted]]

