powered by
Function to find to which matrix indices coordinates correspond (on a 304 x 448 grid)
get_ind(coords, xmn = -3850, ymn = -5350)
coordinates of interest
min x (defaults to value for Northern Polar stereographic grid: -3850)
min y (defaults to value for Northern Polar stereographic grid: -5350)
n x 2 matrix of coordinates on a 304 x 448 grid
# NOT RUN { dat <- matrix(nrow = 2, ncol = 2, data = c(-2000, 0, 300, 1000)) get_ind(dat) # }
Run the code above in your browser using DataLab