{"action":"opened","issue":{"url":"https://api.github.com/repos/johnbaums/things/issues/7","labels_url":"https://api.github.com/repos/johnbaums/things/issues/7/labels{/name}","comments_url":"https://api.github.com/repos/johnbaums/things/issues/7/comments","events_url":"https://api.github.com/repos/johnbaums/things/issues/7/events","html_url":"https://github.com/johnbaums/things/issues/7","id":112665265,"number":7,"title":"see if approx can match performance of interpolate_linear","user":{"login":"johnbaums","id":818438,"avatar_url":"https://avatars.githubusercontent.com/u/818438?v=3","gravatar_id":"","url":"https://api.github.com/users/johnbaums","html_url":"https://github.com/johnbaums","followers_url":"https://api.github.com/users/johnbaums/followers","following_url":"https://api.github.com/users/johnbaums/following{/other_user}","gists_url":"https://api.github.com/users/johnbaums/gists{/gist_id}","starred_url":"https://api.github.com/users/johnbaums/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johnbaums/subscriptions","organizations_url":"https://api.github.com/users/johnbaums/orgs","repos_url":"https://api.github.com/users/johnbaums/repos","events_url":"https://api.github.com/users/johnbaums/events{/privacy}","received_events_url":"https://api.github.com/users/johnbaums/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-10-21T19:46:45Z","updated_at":"2015-10-21T19:46:45Z","closed_at":null,"body":"from @RobertH at http://stackoverflow.com/a/33130289/489704:\r\n\r\n    library(raster)\r\n    r <- raster(nrows=10, ncols=10);\r\n    x1 <- setValues(r, runif(ncell(r)))\r\n    x16 <- setValues(r, runif(ncell(r))) + 10\r\n    x30 <- setValues(r, runif(ncell(r))) + 20\r\n\r\n    s <- stack(x1, x16, x30)\r\n    x <- calc(s, fun=function(y) approx(c(1,16,30), y, 1:30)$y)\r\n\r\n"}}