updates to spatial functions: switch raster to terra #101
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
updates to spatial functions: switch raster to terra
As requested by Dan Moore, updates to the spatial catchment delineation code
Description
The main thing is removing use of the raster package, putting terra in place of it. Additionally, I took out all use of the magrittr package and switched to the base R pipe.
Related Issue
I also fixed one issue with creation of working directories in the spatial data. It is now possible to use relative file paths for data downloads (ch_get_url_data.R).
The temporary folder creation for the spatial data seems to work well. However, I notice that the map function ( ch_get_map_base.R) uses a different method for creating a map data working directory. I recommend Dan and Paul decide on one route to do the same thing in both cases.