-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathsearch.json
1 lines (1 loc) Β· 54.6 KB
/
search.json
1
[{"path":[]},{"path":"https://spatialsample.tidymodels.org/CODE_OF_CONDUCT.html","id":"our-pledge","dir":"","previous_headings":"","what":"Our Pledge","title":"Contributor Covenant Code of Conduct","text":"members, contributors, leaders pledge make participation community harassment-free experience everyone, regardless age, body size, visible invisible disability, ethnicity, sex characteristics, gender identity expression, level experience, education, socio-economic status, nationality, personal appearance, race, caste, color, religion, sexual identity orientation. pledge act interact ways contribute open, welcoming, diverse, inclusive, healthy community.","code":""},{"path":"https://spatialsample.tidymodels.org/CODE_OF_CONDUCT.html","id":"our-standards","dir":"","previous_headings":"","what":"Our Standards","title":"Contributor Covenant Code of Conduct","text":"Examples behavior contributes positive environment community include: Demonstrating empathy kindness toward people respectful differing opinions, viewpoints, experiences Giving gracefully accepting constructive feedback Accepting responsibility apologizing affected mistakes, learning experience Focusing best just us individuals, overall community Examples unacceptable behavior include: use sexualized language imagery, sexual attention advances kind Trolling, insulting derogatory comments, personal political attacks Public private harassment Publishing othersβ private information, physical email address, without explicit permission conduct reasonably considered inappropriate professional setting","code":""},{"path":"https://spatialsample.tidymodels.org/CODE_OF_CONDUCT.html","id":"enforcement-responsibilities","dir":"","previous_headings":"","what":"Enforcement Responsibilities","title":"Contributor Covenant Code of Conduct","text":"Community leaders responsible clarifying enforcing standards acceptable behavior take appropriate fair corrective action response behavior deem inappropriate, threatening, offensive, harmful. Community leaders right responsibility remove, edit, reject comments, commits, code, wiki edits, issues, contributions aligned Code Conduct, communicate reasons moderation decisions appropriate.","code":""},{"path":"https://spatialsample.tidymodels.org/CODE_OF_CONDUCT.html","id":"scope","dir":"","previous_headings":"","what":"Scope","title":"Contributor Covenant Code of Conduct","text":"Code Conduct applies within community spaces, also applies individual officially representing community public spaces. Examples representing community include using official e-mail address, posting via official social media account, acting appointed representative online offline event.","code":""},{"path":"https://spatialsample.tidymodels.org/CODE_OF_CONDUCT.html","id":"enforcement","dir":"","previous_headings":"","what":"Enforcement","title":"Contributor Covenant Code of Conduct","text":"Instances abusive, harassing, otherwise unacceptable behavior may reported community leaders responsible enforcement [email protected]. complaints reviewed investigated promptly fairly. community leaders obligated respect privacy security reporter incident.","code":""},{"path":"https://spatialsample.tidymodels.org/CODE_OF_CONDUCT.html","id":"enforcement-guidelines","dir":"","previous_headings":"","what":"Enforcement Guidelines","title":"Contributor Covenant Code of Conduct","text":"Community leaders follow Community Impact Guidelines determining consequences action deem violation Code Conduct:","code":""},{"path":"https://spatialsample.tidymodels.org/CODE_OF_CONDUCT.html","id":"id_1-correction","dir":"","previous_headings":"Enforcement Guidelines","what":"1. Correction","title":"Contributor Covenant Code of Conduct","text":"Community Impact: Use inappropriate language behavior deemed unprofessional unwelcome community. Consequence: private, written warning community leaders, providing clarity around nature violation explanation behavior inappropriate. public apology may requested.","code":""},{"path":"https://spatialsample.tidymodels.org/CODE_OF_CONDUCT.html","id":"id_2-warning","dir":"","previous_headings":"Enforcement Guidelines","what":"2. Warning","title":"Contributor Covenant Code of Conduct","text":"Community Impact: violation single incident series actions. Consequence: warning consequences continued behavior. interaction people involved, including unsolicited interaction enforcing Code Conduct, specified period time. includes avoiding interactions community spaces well external channels like social media. Violating terms may lead temporary permanent ban.","code":""},{"path":"https://spatialsample.tidymodels.org/CODE_OF_CONDUCT.html","id":"id_3-temporary-ban","dir":"","previous_headings":"Enforcement Guidelines","what":"3. Temporary Ban","title":"Contributor Covenant Code of Conduct","text":"Community Impact: serious violation community standards, including sustained inappropriate behavior. Consequence: temporary ban sort interaction public communication community specified period time. public private interaction people involved, including unsolicited interaction enforcing Code Conduct, allowed period. Violating terms may lead permanent ban.","code":""},{"path":"https://spatialsample.tidymodels.org/CODE_OF_CONDUCT.html","id":"id_4-permanent-ban","dir":"","previous_headings":"Enforcement Guidelines","what":"4. Permanent Ban","title":"Contributor Covenant Code of Conduct","text":"Community Impact: Demonstrating pattern violation community standards, including sustained inappropriate behavior, harassment individual, aggression toward disparagement classes individuals. Consequence: permanent ban sort public interaction within community.","code":""},{"path":"https://spatialsample.tidymodels.org/CODE_OF_CONDUCT.html","id":"attribution","dir":"","previous_headings":"","what":"Attribution","title":"Contributor Covenant Code of Conduct","text":"Code Conduct adapted Contributor Covenant, version 2.1, available https://www.contributor-covenant.org/version/2/1/code_of_conduct.html. Community Impact Guidelines inspired [Mozillaβs code conduct enforcement ladder][https://github.com/mozilla/inclusion]. answers common questions code conduct, see FAQ https://www.contributor-covenant.org/faq. Translations available https://www.contributor-covenant.org/translations.","code":""},{"path":"https://spatialsample.tidymodels.org/CONTRIBUTING.html","id":null,"dir":"","previous_headings":"","what":"Contributing to tidymodels","title":"Contributing to tidymodels","text":"detailed information contributing tidymodels packages, see development contributing guide.","code":""},{"path":"https://spatialsample.tidymodels.org/CONTRIBUTING.html","id":"documentation","dir":"","previous_headings":"","what":"Documentation","title":"Contributing to tidymodels","text":"Typos grammatical errors documentation may edited directly using GitHub web interface, long changes made source file. YES β
: edit roxygen comment .R file R/ directory. π«: edit .Rd file man/ directory. use roxygen2, Markdown syntax, documentation.","code":""},{"path":"https://spatialsample.tidymodels.org/CONTRIBUTING.html","id":"code","dir":"","previous_headings":"","what":"Code","title":"Contributing to tidymodels","text":"submit π― pull request tidymodels package, always file issue confirm tidymodels team agrees idea happy basic proposal. tidymodels packages work together. package contains unit tests, integration tests tests using packages contained extratests. pull requests, recommend create fork repo usethis::create_from_github(), initiate new branch usethis::pr_init(). Look build status making changes. README contains badges continuous integration services used package. New code follow tidyverse style guide. can use styler package apply styles, please donβt restyle code nothing PR. user-facing changes, add bullet top NEWS.md current development version header describing changes made followed GitHub username, links relevant issue(s)/PR(s). use testthat. Contributions test cases included easier accept. contribution spans use one package, consider building extratests changes check breakages /adding new tests . Let us know PR ran extra tests.","code":""},{"path":"https://spatialsample.tidymodels.org/CONTRIBUTING.html","id":"code-of-conduct","dir":"","previous_headings":"Code","what":"Code of Conduct","title":"Contributing to tidymodels","text":"project released Contributor Code Conduct. contributing project, agree abide terms.","code":""},{"path":"https://spatialsample.tidymodels.org/LICENSE.html","id":null,"dir":"","previous_headings":"","what":"MIT License","title":"MIT License","text":"Copyright (c) 2023 spatialsample authors Permission hereby granted, free charge, person obtaining copy software associated documentation files (βSoftwareβ), deal Software without restriction, including without limitation rights use, copy, modify, merge, publish, distribute, sublicense, /sell copies Software, permit persons Software furnished , subject following conditions: copyright notice permission notice shall included copies substantial portions Software. SOFTWARE PROVIDED ββ, WITHOUT WARRANTY KIND, EXPRESS IMPLIED, INCLUDING LIMITED WARRANTIES MERCHANTABILITY, FITNESS PARTICULAR PURPOSE NONINFRINGEMENT. EVENT SHALL AUTHORS COPYRIGHT HOLDERS LIABLE CLAIM, DAMAGES LIABILITY, WHETHER ACTION CONTRACT, TORT OTHERWISE, ARISING , CONNECTION SOFTWARE USE DEALINGS SOFTWARE.","code":""},{"path":"https://spatialsample.tidymodels.org/articles/buffering.html","id":"exclusion-buffers","dir":"Articles","previous_headings":"","what":"Exclusion buffers","title":"Buffering","text":"default, spatial cross-validation methods spatialsample donβt automatically create buffer zones. Take instance spatial_block_cv(), creates number βblocksβ grid assigns data folds based block centroid falls : look individual folds, can see assessment data directly borders analysis data given fold: downside standard blocking cross-validation approaches; introduce spatial separation analysis assessment sets data middle block, data towards edges may separated . Applying exclusion buffer around assessment fold lets us change . create exclusion buffers using cross-validation function spatialsample, can use standardized buffer argument: Now plot folds separately, can see strip data around assessment block assigned neither analysis assessment fold. Instead, βs removed entirely order provide distance two sets: default, buffer assumed units data, determined dataβs coordinate reference system. apply buffers units, use units package explicitly specify units buffer . instance, boston_canopy uses units US feet distance. specify buffer meters instead, can use: Note , βre using non-point data, distance observations calculated shortest distance points two observations. instance, buffers polygon data exclude data based edge--edge distance observations, rather centroid centroid. One special case, however, buffer set 0. case, spatialsample wonβt apply buffer . polygons share edge within 0 distance , calculated edge--edge, think setting buffer = 0 intuitively apply zero (, ) buffer. want sure capture adjacent polygons buffer, set buffer tiny, non-zero value:","code":"set.seed(123) blocks <- spatial_block_cv(boston_canopy, v = 5) autoplot(blocks) purrr::walk(blocks$splits, function(x) print(autoplot(x))) set.seed(123) blocks <- spatial_block_cv(boston_canopy, v = 5, buffer = 1500) purrr::walk(blocks$splits, function(x) print(autoplot(x))) set.seed(123) blocks <- spatial_block_cv( boston_canopy, v = 5, buffer = units::as_units(1500, \"m\") ) purrr::walk(blocks$splits, function(x) print(autoplot(x))) set.seed(123) blocks <- spatial_block_cv( boston_canopy, v = 5, buffer = 2e-200 ) purrr::walk(blocks$splits, function(x) print(autoplot(x)))"},{"path":"https://spatialsample.tidymodels.org/articles/buffering.html","id":"inclusion-radii","dir":"Articles","previous_headings":"","what":"Inclusion radii","title":"Buffering","text":"addition exclusion buffers, spatialsample also provides way add inclusion buffer (call , βinclusion radiusβ) around assessment set. Simply set radius argument spatial cross-validation function desired distance, data within inclusion radius added assessment set: argument handled way buffer, caveats: Unless units specified explicitly, radius assumed units dataβs coordinate reference system. Distances calculated closest parts observations. Values zero apply radius. radius buffer can specified time. makes possible implement, instance, leave-one-disc-cross-validation using spatialsample: radius buffer specified, spatialsample first applies inclusion radius original randomly-selected assessment set, adding data within radius assessment set. Next, exclusion buffer applied points new (post-radius) assessment set, removing data within buffer analysis set. Note means buffer simply applying βdoughnutβ around circular βradiusβ, buffering test point separately. See instance non-uniform buffer region happens βs gap data: leaves data analysis set fitting model, still ensuring assessment data spatially removed.","code":"set.seed(123) blocks <- spatial_block_cv( boston_canopy, v = 5, radius = 2e-200 ) purrr::walk(blocks$splits, function(x) print(autoplot(x))) set.seed(123) blocks <- spatial_buffer_vfold_cv( boston_canopy, v = nrow(boston_canopy), radius = 1500, buffer = 1500 ) purrr::walk(blocks$splits, function(x) print(autoplot(x))) autoplot(blocks$splits[[12]])"},{"path":"https://spatialsample.tidymodels.org/authors.html","id":null,"dir":"","previous_headings":"","what":"Authors","title":"Authors and Citation","text":"Michael Mahoney. Author, maintainer. Julia Silge. Author. . Copyright holder, funder.","code":""},{"path":"https://spatialsample.tidymodels.org/authors.html","id":"citation","dir":"","previous_headings":"","what":"Citation","title":"Authors and Citation","text":"Mahoney M. J., Johnson, L. K., Silge, J., Frick, H., Kuhn, M., Beier C. M. (2023). Assessing performance spatial cross-validation approaches models spatially structured data. arXiv. https://doi.org/10.48550/arXiv.2303.07334","code":"@Misc{, title = {Assessing the performance of spatial cross-validation approaches for models of spatially structured data}, author = {Michael J Mahoney and Lucas K Johnson and Julia Silge and Hannah Frick and Max Kuhn and Colin M Beier}, year = {2023}, eprint = {2303.07334}, archiveprefix = {arXiv}, primaryclass = {stat.CO}, doi = {10.48550/arXiv.2303.07334}, url = {https://arxiv.org/abs/2303.07334}, }"},{"path":[]},{"path":"https://spatialsample.tidymodels.org/index.html","id":"introduction","dir":"","previous_headings":"","what":"Introduction","title":"Spatial Resampling Infrastructure","text":"goal spatialsample provide functions classes spatial resampling use rsample, including: spatial clustering cross-validation spatial block cross-validation spatially buffered cross-validation leave-location-cross-validation Like rsample, spatialsample provides building blocks creating analyzing resamples spatial data set include code modeling computing statistics. resampled data sets created spatialsample efficient much memory overhead.","code":""},{"path":"https://spatialsample.tidymodels.org/index.html","id":"installation","dir":"","previous_headings":"","what":"Installation","title":"Spatial Resampling Infrastructure","text":"can install released version spatialsample CRAN : development version GitHub :","code":"install.packages(\"spatialsample\") # install.packages(\"pak\") pak::pak(\"tidymodels/spatialsample\")"},{"path":"https://spatialsample.tidymodels.org/index.html","id":"example","dir":"","previous_headings":"","what":"Example","title":"Spatial Resampling Infrastructure","text":"straightforward spatial resampling strategy spatial_clustering_cv(), uses k-means clustering identify cross-validation folds: example, boston_canopy data tree cover Boston, MA resampled v = 5; notice resulting partitions contain equal number observations. addition resampling algorithms, spatialsample provides methods visualize resamples using ggplot2 autoplot() function: can use function visualize fold separately: far, βve scratched surface functionality spatialsample provides. information, check Getting Started documentation!","code":"library(spatialsample) set.seed(1234) folds <- spatial_clustering_cv(boston_canopy, v = 5) folds #> # 5-fold spatial cross-validation #> # A tibble: 5 Γ 2 #> splits id #> <list> <chr> #> 1 <split [604/78]> Fold1 #> 2 <split [595/87]> Fold2 #> 3 <split [524/158]> Fold3 #> 4 <split [490/192]> Fold4 #> 5 <split [515/167]> Fold5 autoplot(folds) library(purrr) walk(folds$splits, function(x) print(autoplot(x)))"},{"path":"https://spatialsample.tidymodels.org/index.html","id":"contributing","dir":"","previous_headings":"","what":"Contributing","title":"Spatial Resampling Infrastructure","text":"project released Contributor Code Conduct. contributing project, agree abide terms. questions discussions tidymodels packages, modeling, machine learning, please post RStudio Community. think encountered bug, please submit issue. Either way, learn create share reprex (minimal, reproducible example), clearly communicate code. Check details contributing guidelines tidymodels packages get help.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/autoplot.spatial_rset.html","id":null,"dir":"Reference","previous_headings":"","what":"Create a ggplot for spatial resamples. β autoplot.spatial_rset","title":"Create a ggplot for spatial resamples. β autoplot.spatial_rset","text":"method provides good visualization method spatial resampling.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/autoplot.spatial_rset.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Create a ggplot for spatial resamples. β autoplot.spatial_rset","text":"","code":"# S3 method for class 'spatial_rset' autoplot(object, ..., alpha = 0.6) # S3 method for class 'spatial_block_cv' autoplot(object, show_grid = TRUE, ..., alpha = 0.6)"},{"path":"https://spatialsample.tidymodels.org/reference/autoplot.spatial_rset.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Create a ggplot for spatial resamples. β autoplot.spatial_rset","text":"object spatial_rset object spatial_rsplit object. Note resamples made sf objects create spatial_rset spatial_rsplit objects; function work resamples made non-spatial tibbles data.frames. ... Options passed ggplot2::geom_sf(). alpha Opacity, passed ggplot2::geom_sf(). Values alpha range 0 1, lower values corresponding transparent colors. show_grid plotting spatial_block_cv objects, grid drawn top data? Set FALSE remove grid.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/autoplot.spatial_rset.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"Create a ggplot for spatial resamples. β autoplot.spatial_rset","text":"ggplot object fold assigned color, made using ggplot2::geom_sf().","code":""},{"path":"https://spatialsample.tidymodels.org/reference/autoplot.spatial_rset.html","id":"details","dir":"Reference","previous_headings":"","what":"Details","title":"Create a ggplot for spatial resamples. β autoplot.spatial_rset","text":"plot method spatial_rset displays fold observation assigned . Note data assigned multiple folds (common resamples created non-zero radius) \"last\" fold observation appear plot. Consider adding ggplot2::facet_wrap(~ fold) visualize members fold separately. Alternatively, consider plotting split using spatial_rsplit method (example, via lapply(object$splits, autoplot)).","code":""},{"path":"https://spatialsample.tidymodels.org/reference/autoplot.spatial_rset.html","id":"ref-examples","dir":"Reference","previous_headings":"","what":"Examples","title":"Create a ggplot for spatial resamples. β autoplot.spatial_rset","text":"","code":"boston_block <- spatial_block_cv(boston_canopy, v = 2) autoplot(boston_block) autoplot(boston_block$splits[[1]])"},{"path":"https://spatialsample.tidymodels.org/reference/boston_canopy.html","id":null,"dir":"Reference","previous_headings":"","what":"Boston tree canopy and heat index data. β boston_canopy","title":"Boston tree canopy and heat index data. β boston_canopy","text":"dataset containing data tree canopy coverage change city Boston, Massachusetts 2014-2019, well temperature heat index data July 2019. Data aggregated grid regular 25 hectare hexagons, clipped city boundaries. data made available Public Domain Dedication License v1.0 whose full text can found : https://opendatacommons.org/licenses/pddl/1-0/.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/boston_canopy.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Boston tree canopy and heat index data. β boston_canopy","text":"","code":"boston_canopy"},{"path":"https://spatialsample.tidymodels.org/reference/boston_canopy.html","id":"format","dir":"Reference","previous_headings":"","what":"Format","title":"Boston tree canopy and heat index data. β boston_canopy","text":"data frame (class sf, tbl_df, tbl, data.frame) containing 682 records 22 variables: grid_id Unique identifier hexagon. Letters represent hexagon's X position grid (ordered West East), numbers represent Y position (ordered North South). land_area Area excluding water bodies canopy_gain Area canopy gain two years canopy_loss Area canopy loss two years canopy_no_change Area canopy change two years canopy_area_2014 2014 total canopy area (baseline) canopy_area_2019 2019 total canopy area change_canopy_area change area tree canopy two years change_canopy_percentage Relative change calculation used economics gain loss tree canopy relative earlier time period: (2019 Canopy-2014 Canopy)/(2014 Canopy) canopy_percentage_2014 2014 canopy percentage canopy_percentage_2019 2019 canopy percentage change_canopy_absolute Absolute change. Magnitude change percent tree canopy 2014 2019 (% 2019 Canopy - % 2014 Canopy) mean_temp_morning Mean temperature July 2019 6am - 7am mean_temp_evening Mean temperature July 2019 7pm - 8pm mean_temp Mean temperature July 2019 6am - 7am, 3pm - 4pm, 7pm - 8pm (combined) mean_heat_index_morning Mean heat index July 2019 6am - 7am mean_heat_index_evening Mean heat index July 2019 7pm - 8pm mean_heat_index Mean heat index July 2019 6am - 7am, 3pm - 4pm, 7pm - 8pm (combined) geometry Geometry hexagon, encoded using EPSG:2249 coordinate reference system (NAD83 / Massachusetts Mainland (ftUS)). Note linear units CRS US feet.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/boston_canopy.html","id":"source","dir":"Reference","previous_headings":"","what":"Source","title":"Boston tree canopy and heat index data. β boston_canopy","text":"Canopy data https://data.boston.gov/dataset/hex-tree-canopy-change-metrics. Heat data https://data.boston.gov/dataset/hex-mean-heat-index. field definitions https://data.boston.gov/dataset/canopy-change-assessment-data-dictionary.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/boston_canopy.html","id":"details","dir":"Reference","previous_headings":"","what":"Details","title":"Boston tree canopy and heat index data. β boston_canopy","text":"Note dataset EPSG:2249 (NAD83 / Massachusetts Mainland (ftUS)) coordinate reference system (CRS), may installed default computer. working boston_canopy, run: sf::sf_proj_network(TRUE) install CRS sf::sf_add_proj_units() add US customary units units database steps need taken per computer (per PROJ installation).","code":""},{"path":"https://spatialsample.tidymodels.org/reference/buffer_indices.html","id":null,"dir":"Reference","previous_headings":"","what":"Apply an inclusion radius and exclusion buffer to indices β buffer_indices","title":"Apply an inclusion radius and exclusion buffer to indices β buffer_indices","text":"Apply inclusion radius exclusion buffer indices","code":""},{"path":"https://spatialsample.tidymodels.org/reference/buffer_indices.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Apply an inclusion radius and exclusion buffer to indices β buffer_indices","text":"","code":"buffer_indices(data, indices, radius, buffer, call = rlang::caller_env())"},{"path":"https://spatialsample.tidymodels.org/reference/buffer_indices.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Apply an inclusion radius and exclusion buffer to indices β buffer_indices","text":"data object class sf sfc. indices List indices fold generated split_unnamed(). radius Numeric: points within distance initially-selected test points assigned assessment set. NULL, radius applied. buffer Numeric: points within distance point test set (radius applied) assigned neither analysis assessment set. NULL, buffer applied.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/check_v.html","id":null,"dir":"Reference","previous_headings":"","what":"Check that ","title":"Check that ","text":"Check \"v\" sensible","code":""},{"path":"https://spatialsample.tidymodels.org/reference/check_v.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Check that ","text":"","code":"check_v(v, max_v, objects, allow_max_v = TRUE, call = rlang::caller_env())"},{"path":"https://spatialsample.tidymodels.org/reference/check_v.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Check that ","text":"v number partitions resampling. Set NULL Inf maximum sensible value (leave-one-X-cross-validation).","code":""},{"path":"https://spatialsample.tidymodels.org/reference/reexports.html","id":null,"dir":"Reference","previous_headings":"","what":"Objects exported from other packages β reexports","title":"Objects exported from other packages β reexports","text":"objects imported packages. Follow links see documentation. ggplot2 autoplot rsample analysis, assessment, get_rsplit","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_block_cv.html","id":null,"dir":"Reference","previous_headings":"","what":"Spatial block cross-validation β spatial_block_cv","title":"Spatial block cross-validation β spatial_block_cv","text":"Block cross-validation splits area data number grid cells, \"blocks\", assigns data folds based blocks centroid falls .","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_block_cv.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Spatial block cross-validation β spatial_block_cv","text":"","code":"spatial_block_cv( data, method = c(\"random\", \"snake\", \"continuous\"), v = 10, relevant_only = TRUE, radius = NULL, buffer = NULL, ..., repeats = 1, expand_bbox = 1e-05 )"},{"path":"https://spatialsample.tidymodels.org/reference/spatial_block_cv.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Spatial block cross-validation β spatial_block_cv","text":"data object class sf sfc. method method used sample blocks cross validation folds. Currently supports \"random\", randomly assigns blocks folds, \"snake\", labels first row blocks left right, next right left, repeats , \"continuous\", labels row left right, moving bottom row . v number partitions resampling. Set NULL Inf maximum sensible value (leave-one-X-cross-validation). relevant_only systematic sampling, blocks containing data included fold labeling? radius Numeric: points within distance initially-selected test points assigned assessment set. NULL, radius applied. buffer Numeric: points within distance point test set (radius applied) assigned neither analysis assessment set. NULL, buffer applied. ... Arguments passed sf::st_make_grid(). repeats number times repeat V-fold partitioning. expand_bbox numeric length 1, representing proportion expand bounding box data building grid. Without expansion, grids built data geographic coordinates may exclude observations grids built regularly spaced data might observations fall exactly boundary folds, duplicating . spatialsample < 0.5.0, 0.00001 data geographic CRS 0 data planar CRS. spatialsample >= 0.5.0, 0.00001 data.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_block_cv.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"Spatial block cross-validation β spatial_block_cv","text":"tibble classes spatial_block_cv, spatial_rset, rset, tbl_df, tbl, data.frame. results include column data split objects identification variable id.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_block_cv.html","id":"details","dir":"Reference","previous_headings":"","what":"Details","title":"Spatial block cross-validation β spatial_block_cv","text":"grid blocks can controlled passing arguments sf::st_make_grid() via .... particularly useful arguments include: cellsize: Target cellsize, expressed \"diameter\" (shortest straight-line distance opposing sides; two times apothem) block, map units. n: number grid blocks x y direction (columns, rows). square: logical value indicating whether create square (TRUE) hexagonal (FALSE) cells. cellsize n provided, number blocks requested n sizes specified cellsize returned, likely lining bounding box data. cellsize provided, function return many blocks size cellsize fit inside bounding box data. n provided, cellsize automatically adjusted create requested number cells.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_block_cv.html","id":"references","dir":"Reference","previous_headings":"","what":"References","title":"Spatial block cross-validation β spatial_block_cv","text":"D. R. Roberts, V. Bahn, S. Ciuti, M. S. Boyce, J. Elith, G. Guillera-Arroita, S. Hauenstein, J. J. Lahoz-Monfort, B. SchrΓΆder, W. Thuiller, D. . Warton, B. . Wintle, F. Hartig, C. F. Dormann. \"Cross-validation strategies data temporal, spatial, hierarchical, phylogenetic structure,\" 2016, Ecography 40(8), pp. 913-929, doi: 10.1111/ecog.02881.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_block_cv.html","id":"ref-examples","dir":"Reference","previous_headings":"","what":"Examples","title":"Spatial block cross-validation β spatial_block_cv","text":"","code":"spatial_block_cv(boston_canopy, v = 3) #> # 3-fold spatial block cross-validation #> # A tibble: 3 Γ 2 #> splits id #> <list> <chr> #> 1 <split [455/227]> Fold1 #> 2 <split [481/201]> Fold2 #> 3 <split [428/254]> Fold3"},{"path":"https://spatialsample.tidymodels.org/reference/spatial_clustering_cv.html","id":null,"dir":"Reference","previous_headings":"","what":"Spatial Clustering Cross-Validation β spatial_clustering_cv","title":"Spatial Clustering Cross-Validation β spatial_clustering_cv","text":"Spatial clustering cross-validation splits data V groups disjointed sets clustering points based spatial coordinates. resample analysis data consists V-1 folds/clusters assessment set contains final fold/cluster.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_clustering_cv.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Spatial Clustering Cross-Validation β spatial_clustering_cv","text":"","code":"spatial_clustering_cv( data, v = 10, cluster_function = c(\"kmeans\", \"hclust\"), radius = NULL, buffer = NULL, ..., repeats = 1, distance_function = function(x) as.dist(sf::st_distance(x)) )"},{"path":"https://spatialsample.tidymodels.org/reference/spatial_clustering_cv.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Spatial Clustering Cross-Validation β spatial_clustering_cv","text":"data sf object (often sf::read_sf() sf::st_as_sf()) split folds. v number partitions data set. cluster_function function used clustering? Options either \"kmeans\" (use stats::kmeans()) \"hclust\" (use stats::hclust()). can also provide function; see Details. radius Numeric: points within distance initially-selected test points assigned assessment set. NULL, radius applied. buffer Numeric: points within distance point test set (radius applied) assigned neither analysis assessment set. NULL, buffer applied. ... Extra arguments passed stats::kmeans() stats::hclust(). repeats number times repeat clustered partitioning. distance_function function used distance calculations? Defaults sf::st_distance(), output matrix converted stats::dist() object. can also provide function; see Details.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_clustering_cv.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"Spatial Clustering Cross-Validation β spatial_clustering_cv","text":"tibble classes spatial_clustering_cv, spatial_rset, rset, tbl_df, tbl, data.frame. results include column data split objects identification variable id. Resamples created non-sf objects spatial_rset class.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_clustering_cv.html","id":"details","dir":"Reference","previous_headings":"","what":"Details","title":"Spatial Clustering Cross-Validation β spatial_clustering_cv","text":"Clusters created based distances observations data sf object. cluster used fold cross-validation. Depending data distributed spatially, may equal number observations fold. can optionally provide custom function distance_function. function take sf object return stats::dist() object distances data points. can optionally provide custom function cluster_function. function must take three arguments: dists, stats::dist() object distances data points v, length-1 numeric number folds create ..., pass additional named arguments function function return vector cluster assignments length nrow(data), element vector corresponding matching row data frame.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_clustering_cv.html","id":"changes-in-spatialsample-","dir":"Reference","previous_headings":"","what":"Changes in spatialsample 0.3.0","title":"Spatial Clustering Cross-Validation β spatial_clustering_cv","text":"spatialsample version 0.3.0, function longer accepts non-sf objects arguments data. order perform clustering non-spatial data, consider using rsample::clustering_cv(). Also version 0.3.0, function now calculates edge--edge distance non-point geometries, line rest package. Earlier versions relied upon -centroid distances.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_clustering_cv.html","id":"references","dir":"Reference","previous_headings":"","what":"References","title":"Spatial Clustering Cross-Validation β spatial_clustering_cv","text":". Brenning, \"Spatial cross-validation bootstrap assessment prediction rules remote sensing: R package sperrorest,\" 2012 IEEE International Geoscience Remote Sensing Symposium, Munich, 2012, pp. 5372-5375, doi: 10.1109/IGARSS.2012.6352393.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_clustering_cv.html","id":"ref-examples","dir":"Reference","previous_headings":"","what":"Examples","title":"Spatial Clustering Cross-Validation β spatial_clustering_cv","text":"","code":"data(Smithsonian, package = \"modeldata\") smithsonian_sf <- sf::st_as_sf( Smithsonian, coords = c(\"longitude\", \"latitude\"), # Set CRS to WGS84 crs = 4326 ) # When providing sf objects, coords are inferred automatically spatial_clustering_cv(smithsonian_sf, v = 5) #> # 5-fold spatial cross-validation #> # A tibble: 5 Γ 2 #> splits id #> <list> <chr> #> 1 <split [9/11]> Fold1 #> 2 <split [16/4]> Fold2 #> 3 <split [18/2]> Fold3 #> 4 <split [18/2]> Fold4 #> 5 <split [19/1]> Fold5 # Can use hclust instead: spatial_clustering_cv(smithsonian_sf, v = 5, cluster_function = \"hclust\") #> # 5-fold spatial cross-validation #> # A tibble: 5 Γ 2 #> splits id #> <list> <chr> #> 1 <split [19/1]> Fold1 #> 2 <split [4/16]> Fold2 #> 3 <split [19/1]> Fold3 #> 4 <split [19/1]> Fold4 #> 5 <split [19/1]> Fold5"},{"path":"https://spatialsample.tidymodels.org/reference/spatial_nndm_cv.html","id":null,"dir":"Reference","previous_headings":"","what":"Nearest neighbor distance matching (NNDM) cross-validation β spatial_nndm_cv","title":"Nearest neighbor distance matching (NNDM) cross-validation β spatial_nndm_cv","text":"NNDM variant leave-one-cross-validation assigns observation single assessment fold, attempts remove data analysis fold nearest neighbor distance distribution assessment analysis folds matches nearest neighbor distance distribution training data locations model used predict. Proposed MilΓ et al. (2022), method aims provide accurate estimates well models perform locations actually predicting. method originally implemented CAST package.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_nndm_cv.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Nearest neighbor distance matching (NNDM) cross-validation β spatial_nndm_cv","text":"","code":"spatial_nndm_cv( data, prediction_sites, ..., autocorrelation_range = NULL, prediction_sample_size = 1000, min_analysis_proportion = 0.5 )"},{"path":"https://spatialsample.tidymodels.org/reference/spatial_nndm_cv.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Nearest neighbor distance matching (NNDM) cross-validation β spatial_nndm_cv","text":"data object class sf sfc. prediction_sites sf sfc object describing areas predicted. prediction_sites points, points treated intended prediction points calculating target nearest neighbor distances. prediction_sites single (multi-)polygon, points sampled within boundaries polygon. Otherwise, prediction_sites length > 1 made points, points sampled within bounding box prediction_sites used intended prediction points. ... Additional arguments passed sf::st_sample(). Note number points sample controlled prediction_sample_size; trying pass size via ... cause error. autocorrelation_range numeric length 1 representing landscape autocorrelation range (\"phi\" terminology MilΓ et al. (2022)). NULL, default, autocorrelation range assumed distance opposite corners bounding box prediction_sites. prediction_sample_size numeric length 1: number points sample prediction_sites composed points. Note argument passed size sf::st_sample(), meaning elements ... can named size. min_analysis_proportion minimum proportion data must remain removing points match nearest neighbor distances. function stop removing data analysis sets min_analysis_proportion original data remains analysis sets, even nearest neighbor distances analysis assessment sets still lower training prediction locations.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_nndm_cv.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"Nearest neighbor distance matching (NNDM) cross-validation β spatial_nndm_cv","text":"tibble classes spatial_nndm_cv, spatial_rset, rset, tbl_df, tbl, data.frame. results include column data split objects identification variable id.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_nndm_cv.html","id":"details","dir":"Reference","previous_headings":"","what":"Details","title":"Nearest neighbor distance matching (NNDM) cross-validation β spatial_nndm_cv","text":"Note , form leave-one-cross-validation, method can rather slow larger data (fitting models resamples even slower).","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_nndm_cv.html","id":"references","dir":"Reference","previous_headings":"","what":"References","title":"Nearest neighbor distance matching (NNDM) cross-validation β spatial_nndm_cv","text":"C. MilΓ , J. Mateu, E. Pebesma, H. Meyer. 2022. \"Nearest Neighbour Distance Matching Leave-One-Cross-Validation map validation.\" Methods Ecology Evolution 2022:13, pp 1304β 1316. doi: 10.1111/2041-210X.13851. H. Meyer E. Pebesma. 2022. \"Machine learning-based global maps ecological variables challenge assessing .\" Nature Communications 13, pp 2208. doi: 10.1038/s41467-022-29838-9.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_nndm_cv.html","id":"ref-examples","dir":"Reference","previous_headings":"","what":"Examples","title":"Nearest neighbor distance matching (NNDM) cross-validation β spatial_nndm_cv","text":"","code":"data(ames, package = \"modeldata\") ames_sf <- sf::st_as_sf(ames, coords = c(\"Longitude\", \"Latitude\"), crs = 4326) # Using a small subset of the data, to make the example run faster: spatial_nndm_cv(ames_sf[1:100, ], ames_sf[2001:2100, ]) #> # A tibble: 100 Γ 2 #> splits id #> <list> <chr> #> 1 <split [50/1]> Fold001 #> 2 <split [83/1]> Fold002 #> 3 <split [50/1]> Fold003 #> 4 <split [50/1]> Fold004 #> 5 <split [50/1]> Fold005 #> 6 <split [50/1]> Fold006 #> 7 <split [50/1]> Fold007 #> 8 <split [76/1]> Fold008 #> 9 <split [86/1]> Fold009 #> 10 <split [88/1]> Fold010 #> # βΉ 90 more rows"},{"path":"https://spatialsample.tidymodels.org/reference/spatial_vfold.html","id":null,"dir":"Reference","previous_headings":"","what":"V-Fold Cross-Validation with Buffering β spatial_buffer_vfold_cv","title":"V-Fold Cross-Validation with Buffering β spatial_buffer_vfold_cv","text":"V-fold cross-validation (also known k-fold cross-validation) randomly splits data V groups roughly equal size (called \"folds\"). resample analysis data consists V-1 folds assessment set contains final fold. functions extend rsample::vfold_cv() rsample::group_vfold_cv() also apply inclusion radius exclusion buffer assessment set, ensuring analysis data spatially separated assessment set. basic V-fold cross-validation (.e. repeats), number resamples equal V.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_vfold.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"V-Fold Cross-Validation with Buffering β spatial_buffer_vfold_cv","text":"","code":"spatial_buffer_vfold_cv( data, radius, buffer, v = 10, repeats = 1, strata = NULL, breaks = 4, pool = 0.1, ... ) spatial_leave_location_out_cv( data, group, v = NULL, radius = NULL, buffer = NULL, ..., repeats = 1 )"},{"path":"https://spatialsample.tidymodels.org/reference/spatial_vfold.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"V-Fold Cross-Validation with Buffering β spatial_buffer_vfold_cv","text":"data data frame. radius Numeric: points within distance initially-selected test points assigned assessment set. NULL, radius applied. buffer Numeric: points within distance point test set (radius applied) assigned neither analysis assessment set. NULL, buffer applied. v number partitions resampling. Set NULL Inf maximum sensible value (leave-one-X-cross-validation). repeats number times repeat V-fold partitioning. strata variable data (single character name) used conduct stratified sampling. NULL, resample created within stratification variable. Numeric strata binned quartiles. breaks single number giving number bins desired stratify numeric stratification variable. pool proportion data used determine particular group small pooled another group. recommend decreasing argument default 0.1 dangers stratifying groups small. ... dots future extensions must empty. group variable data (single character name) used create folds. leave-location-CV, variable containing locations group observations , leave-time-CV time blocks group , leave-location--time-spatiotemporal blocks group .","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_vfold.html","id":"details","dir":"Reference","previous_headings":"","what":"Details","title":"V-Fold Cross-Validation with Buffering β spatial_buffer_vfold_cv","text":"radius buffer NULL, spatial_buffer_vfold_cv equivalent rsample::vfold_cv() spatial_leave_location_out_cv equivalent rsample::group_vfold_cv().","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_vfold.html","id":"references","dir":"Reference","previous_headings":"","what":"References","title":"V-Fold Cross-Validation with Buffering β spatial_buffer_vfold_cv","text":"K. Le Rest, D. Pinaud, P. Monestiez, J. Chadoeuf, C. Bretagnolle. 2014. \"Spatial leave-one-cross-validation variable selection presence spatial autocorrelation,\" Global Ecology Biogeography 23, pp. 811-820, doi: 10.1111/geb.12161. H. Meyer, C. Reudenbach, T. Hengl, M. Katurji, T. Nauss. 2018. \"Improving performance spatio-temporal machine learning models using forward feature selection target-oriented validation,\" Environmental Modelling & Software 101, pp. 1-9, doi: 10.1016/j.envsoft.2017.12.001.","code":""},{"path":"https://spatialsample.tidymodels.org/reference/spatial_vfold.html","id":"ref-examples","dir":"Reference","previous_headings":"","what":"Examples","title":"V-Fold Cross-Validation with Buffering β spatial_buffer_vfold_cv","text":"","code":"data(Smithsonian, package = \"modeldata\") Smithsonian_sf <- sf::st_as_sf( Smithsonian, coords = c(\"longitude\", \"latitude\"), crs = 4326 ) spatial_buffer_vfold_cv( Smithsonian_sf, buffer = 500, radius = NULL ) #> # 10-fold spatial cross-validation #> # A tibble: 10 Γ 2 #> splits id #> <list> <chr> #> 1 <split [11/2]> Fold01 #> 2 <split [17/2]> Fold02 #> 3 <split [11/2]> Fold03 #> 4 <split [11/2]> Fold04 #> 5 <split [11/2]> Fold05 #> 6 <split [11/2]> Fold06 #> 7 <split [17/2]> Fold07 #> 8 <split [17/2]> Fold08 #> 9 <split [11/2]> Fold09 #> 10 <split [13/2]> Fold10 data(ames, package = \"modeldata\") ames_sf <- sf::st_as_sf(ames, coords = c(\"Longitude\", \"Latitude\"), crs = 4326) ames_neighborhoods <- spatial_leave_location_out_cv(ames_sf, Neighborhood)"},{"path":"https://spatialsample.tidymodels.org/reference/spatialsample-package.html","id":null,"dir":"Reference","previous_headings":"","what":"spatialsample: Spatial Resampling Infrastructure β spatialsample-package","title":"spatialsample: Spatial Resampling Infrastructure β spatialsample-package","text":"Functions classes spatial resampling use 'rsample' package, spatial cross-validation (Brenning, 2012) doi:10.1109/IGARSS.2012.6352393 . scope 'rsample' 'spatialsample' provide basic building blocks creating analyzing resamples spatial data set, neither package includes functions modeling computing statistics. resampled spatial data sets created 'spatialsample' contain much overhead memory.","code":""},{"path":[]},{"path":"https://spatialsample.tidymodels.org/reference/spatialsample-package.html","id":"author","dir":"Reference","previous_headings":"","what":"Author","title":"spatialsample: Spatial Resampling Infrastructure β spatialsample-package","text":"Maintainer: Michael Mahoney [email protected] (ORCID) Authors: Julia Silge [email protected] (ORCID) contributors: Posit Software, PBC [copyright holder, funder]","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"spatialsample-060","dir":"Changelog","previous_headings":"","what":"spatialsample 0.6.0","title":"spatialsample 0.6.0","text":"CRAN release: 2024-10-02 Fixed bug passing polygon spatial_nndm_cv() forced leave-one-CV, rather intended sampling prediction points polygon.","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"spatialsample-051","dir":"Changelog","previous_headings":"","what":"spatialsample 0.5.1","title":"spatialsample 0.5.1","text":"CRAN release: 2023-11-07 spatial_block_cv() now adds expand_bbox attribute resulting rset compatibility rsample::reshuffle_rset() autoplot.spatial_block_cv() now plots proper grid (using new expand_bbox attribute).","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"spatialsample-050","dir":"Changelog","previous_headings":"","what":"spatialsample 0.5.0","title":"spatialsample 0.5.0","text":"CRAN release: 2023-11-03 spatial_block_cv() gains argument, expand_bbox, represents proportion bounding box expanded (corner bounding box expanded bbox_corner_value * expand_bbox). breaking change data planar coordinate reference systems. Set 0 obtain previous behaviors. Data geographic coordinates already bounding box expanded default 0.00001. makes regularly spaced data less likely fall precisely along grid lines (therefore fall two assessment sets) geographic data falls likely fall within constructed grid. Thanks Nikos StackOverflow reporting behavior: https://stackoverflow.com/q/77374348/9625040 spatial_block_cv() now throw error observations multiple assessment folds (caused observations, observation centroids, falling precisely along grid polygon boundaries). spatial_nndm_cv(), passing single polygon (multipolygon) prediction_sites argument result prediction sites sampled polygon, rather bounding box. get_rsplit() now re-exported rsample package. provides natural, pipe-able interface accessing individual splits; get_rsplit(rset, 1) identical rset$splits[[1]].","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"spatialsample-040","dir":"Changelog","previous_headings":"","what":"spatialsample 0.4.0","title":"spatialsample 0.4.0","text":"CRAN release: 2023-05-17 spatial_nndm_cv() new function nearest neighbor distance matching cross-validation, described MilΓ et al.Β 2022 (doi: 10.1111/2041-210X.13851). NNDM first implemented CAST (https://cran.r-project.org/package=CAST).","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"spatialsample-030","dir":"Changelog","previous_headings":"","what":"spatialsample 0.3.0","title":"spatialsample 0.3.0","text":"CRAN release: 2023-01-17","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"breaking-changes-0-3-0","dir":"Changelog","previous_headings":"","what":"Breaking changes","title":"spatialsample 0.3.0","text":"spatial_clustering_cv() longer accepts non-sf objects. Use rsample::clustering_cv() instead (#126). spatial_clustering_cv() now uses edge--edge distances, like rest package, rather centroids (#126).","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"new-features-0-3-0","dir":"Changelog","previous_headings":"","what":"New features","title":"spatialsample 0.3.0","text":"functions now repeats argument, defaulting 1, allowing repeated cross-validation (#122, #125, #126). spatial_clustering_cv() now distance_function argument, set default .dist(sf::st_distance(x)) (#126).","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"minor-improvements-and-fixes-0-3-0","dir":"Changelog","previous_headings":"","what":"Minor improvements and fixes","title":"spatialsample 0.3.0","text":"Outputs spatial_buffer_vfold_cv() now correct radius buffer attributes (#110). spatial_buffer_vfold_cv() now correct id values using repeats (#116). spatial_buffer_vfold_cv() now throws error repeats > 1 && v >= nrow(data) (#116). minimum sf version required now >= 1.0-9, unit objects can passed cellsize spatial_block_cv() (#113; #124). autoplot() now handles repeated cross-validation properly (#123).","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"spatialsample-021","dir":"Changelog","previous_headings":"","what":"spatialsample 0.2.1","title":"spatialsample 0.2.1","text":"CRAN release: 2022-08-05 Mike Mahoney taking package maintainer, Julia Silge (remains package author) moves focus ModelOps work. Functions now return rsplits without out_id, like rsample functions, whenever buffer NULL. spatial_block_cv(), spatial_buffer_vfold_cv(), buffering now support using sf sfc objects missing CRS. assumption data NA CRS projected, distance values unit projection. Trying use alternative units fail. Set CRS assumptions arenβt correct. spatial_buffer_vfold_cv() buffering longer support tibble data.frame inputs (now require sf sfc objects). easy use begin , always caused error: use rsample::vfold_cv() instead transform data sf object. spatial_buffer_vfold_cv() attribute changes match rsample: strata attribute now name column used stratification, set stratification. pool breaks added attributes radius buffer now set 0 passed NULL.","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"spatialsample-020","dir":"Changelog","previous_headings":"","what":"spatialsample 0.2.0","title":"spatialsample 0.2.0","text":"CRAN release: 2022-06-17","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"new-features-0-2-0","dir":"Changelog","previous_headings":"","what":"New features","title":"spatialsample 0.2.0","text":"spatial_buffer_vfold_cv() new function wraps rsample::vfold_cv(), allowing users add inclusion radii exclusion buffers vfold resamples. supported way perform spatially buffered leave-one-cross validation (set v nrow(data)). spatial_leave_location_out_cv() new function wraps rsample::group_vfold_cv(), allowing users add inclusion radii exclusion buffers vfold resamples. spatial_block_cv() new function performing spatial block cross-validation. currently supports randomly assigning blocks folds. spatial_clustering_cv() gains argument, cluster_function, specifies type clustering perform. cluster_function = \"kmeans\", default, uses stats::kmeans() k-means clustering, cluster_function = \"hclust\" uses stats::hclust() hierarchical clustering. Users can also provide clustering function. spatial_clustering_cv() now supports sf objects! Coordinates inferred automatically using sf objects, anything passed coords ignored warning. Clusters made using sf objects take coordinate reference systems account (using sf::st_distance()), unlike made using data frames. resampling functions now support spatial buffering using two arguments. radius lets specify inclusion radius test set, data within radius original assessment set added assessment set. buffer specifies exclusion buffer around test set, data within buffer assessment set (radius applied) excluded sets. autoplot() now method spatial resamples built sf objects. works rset objects rsplit objects, special method outputs spatial_block_cv(). boston_canopy new dataset data tree canopy change time Boston, Massachusetts, USA. uses projected coordinate reference system US customary units; see ?boston_canopy instructions install PROJ installation needed.","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"documentation-0-2-0","dir":"Changelog","previous_headings":"","what":"Documentation","title":"spatialsample 0.2.0","text":"βGetting Startedβ vignette revised demonstrate new features clustering methods. new vignette added walking spatial buffering process.","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"dependency-changes-0-2-0","dir":"Changelog","previous_headings":"","what":"Dependency changes","title":"spatialsample 0.2.0","text":"R versions 3.4 longer supported. glue, sf, units added Imports. ggplot2 moved Imports. Suggests. covr, gifski, lwgeom, vdiffr now Suggests. rlang now minimum version 1.0.0 (previously unversioned).","code":""},{"path":"https://spatialsample.tidymodels.org/news/index.html","id":"spatialsample-010","dir":"Changelog","previous_headings":"","what":"spatialsample 0.1.0","title":"spatialsample 0.1.0","text":"CRAN release: 2021-03-04 Added NEWS.md file track changes package.","code":""}]