Weiming-Hu / RAnEnExtra

This is a R package that contains helpful functions for the RAnEn package.
https://weiming-hu.github.io/RAnEnExtra/
MIT License
0 stars 2 forks source link

subsetCoordinates POI check #1

Closed map579 closed 4 years ago

map579 commented 4 years ago

The subsetCoordinates function currently only checks to see if the input Points of Interest are a vector, whereas the prior version included a check to see if the POI were a data frame. The inclusion of a check for POI as a data frame is useful, as observations may be at varying locations other than in a grid format.

subset.coords <- subsetCoordinates(

  • fore.coords$X, fore.coords$Y, obs.coords) Error in subsetCoordinates(fore.coords$X, fore.coords$Y, obs.coords) : The input poi can should be a named vector is.vector(obs.coords) [1] FALSE is.data.frame(obs.coords) [1] TRUE

Thanks! - Mark

Weiming-Hu commented 4 years ago

This has been added in commit 9946e36f5834d49e0f88410684fb4dc773c869a3.

Please simply reinstall to update to the latest version try this out.

If it works, please close the ticket. Thanks

map579 commented 4 years ago

I checked the function using both methods (poi and data frame) and they both work. Thank you, Weiming!