{"action":"created","issue":{"url":"https://api.github.com/repos/seantuck12/MODISTools/issues/14","labels_url":"https://api.github.com/repos/seantuck12/MODISTools/issues/14/labels{/name}","comments_url":"https://api.github.com/repos/seantuck12/MODISTools/issues/14/comments","events_url":"https://api.github.com/repos/seantuck12/MODISTools/issues/14/events","html_url":"https://github.com/seantuck12/MODISTools/issues/14","id":96328449,"number":14,"title":"Best way to handle explicilty spatio-temporal data?","user":{"login":"ethanwhite","id":744427,"avatar_url":"https://avatars.githubusercontent.com/u/744427?v=3","gravatar_id":"","url":"https://api.github.com/users/ethanwhite","html_url":"https://github.com/ethanwhite","followers_url":"https://api.github.com/users/ethanwhite/followers","following_url":"https://api.github.com/users/ethanwhite/following{/other_user}","gists_url":"https://api.github.com/users/ethanwhite/gists{/gist_id}","starred_url":"https://api.github.com/users/ethanwhite/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ethanwhite/subscriptions","organizations_url":"https://api.github.com/users/ethanwhite/orgs","repos_url":"https://api.github.com/users/ethanwhite/repos","events_url":"https://api.github.com/users/ethanwhite/events{/privacy}","received_events_url":"https://api.github.com/users/ethanwhite/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-07-21T14:23:31Z","updated_at":"2015-07-21T15:25:25Z","closed_at":null,"body":"I'm using MODISTools to combine MODIS data with biological data that is both spatially and temporally explicit. E.g.,:\r\n\r\n```\r\nlat,long,year,richness\r\n25.1,-81.1,2000,28\r\n25.1,-81.1,2001,32\r\n26.2,-80.5,2000,42\r\n26.2,-80.5,2001,38\r\n```\r\n\r\nI'm trying to figure out the best way to add a column(s) to this data frame that includes vegetation indices (e.g., NDVI), where the value of NDVI is specific to both the geographic coordinates and the year (eventually being able to only include date for a specific portion of the year).\r\n\r\nI originally used `MODISSubsets` to download the entire time-series (all years) for each location, but I'm open to downloading individual years (or parts of years) separately. Basically I'm just looking for a little expert guidance on the best way to accomplish this. Thanks in advance (and thanks again for all the help you've already provided) and apologies if I've missed something obvious in the docs."},"comment":{"url":"https://api.github.com/repos/seantuck12/MODISTools/issues/comments/123369400","html_url":"https://github.com/seantuck12/MODISTools/issues/14#issuecomment-123369400","issue_url":"https://api.github.com/repos/seantuck12/MODISTools/issues/14","id":123369400,"user":{"login":"helenphillips","id":2923026,"avatar_url":"https://avatars.githubusercontent.com/u/2923026?v=3","gravatar_id":"","url":"https://api.github.com/users/helenphillips","html_url":"https://github.com/helenphillips","followers_url":"https://api.github.com/users/helenphillips/followers","following_url":"https://api.github.com/users/helenphillips/following{/other_user}","gists_url":"https://api.github.com/users/helenphillips/gists{/gist_id}","starred_url":"https://api.github.com/users/helenphillips/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/helenphillips/subscriptions","organizations_url":"https://api.github.com/users/helenphillips/orgs","repos_url":"https://api.github.com/users/helenphillips/repos","events_url":"https://api.github.com/users/helenphillips/events{/privacy}","received_events_url":"https://api.github.com/users/helenphillips/received_events","type":"User","site_admin":false},"created_at":"2015-07-21T15:25:24Z","updated_at":"2015-07-21T15:25:24Z","body":"Assuming I've understood correctly, the easiest way would be to append a start.date column to the dataset submitted to the MODISSubsets function (specifying StartDate = TRUE), in either POSIXt format, for a specific date range, or the year only, for the entire year's data. \r\n\r\nMODISSubsets downloads each unique line individually so will be able to handle all spatially and temporally explicit data.  MODISSummaries will then append the VI data to the original dataframe, and save as a csv file with a VI column (or multiple, if multiple VIs were inputted into MODISSummaries). \r\n\r\nHope that helps! Potentially we need to go through help files and make them a bit clearer...."}}