From 98be7e033c7f039c18d5a2ce0aa1d0108610d4a5 Mon Sep 17 00:00:00 2001 From: SpatLyu Date: Sun, 29 Sep 2024 07:51:49 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20ausgis/g?= =?UTF-8?q?eosimilarity@e0e87b0e05b97442c5b6855733b658a7f92030ff=20?= =?UTF-8?q?=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- articles/geosimilarity.html | 2 +- authors.html | 2 +- news/index.html | 2 +- pkgdown.yml | 2 +- reference/gos.html | 4 ++-- reference/gos_bestkappa.html | 4 ++-- reference/grid.html | 2 +- reference/pipe.html | 2 +- reference/removeoutlier.html | 2 +- reference/zn.html | 2 +- search.json | 2 +- 11 files changed, 13 insertions(+), 13 deletions(-) diff --git a/articles/geosimilarity.html b/articles/geosimilarity.html index 66d8881..84e1667 100644 --- a/articles/geosimilarity.html +++ b/articles/geosimilarity.html @@ -68,7 +68,7 @@

Geographically Optimal Similarity (GOS) and the Third Law of Geography in R

- Source: vignettes/geosimilarity.Rmd + Source: vignettes/geosimilarity.Rmd
geosimilarity.Rmd
diff --git a/authors.html b/authors.html index 29364ce..9f83eb6 100644 --- a/authors.html +++ b/authors.html @@ -57,7 +57,7 @@

Authors

Citation

-

Source: inst/CITATION

+

Source: inst/CITATION

Yongze S (2022). “Geographically Optimal Similarity.” diff --git a/news/index.html b/news/index.html index a58691c..61a309b 100644 --- a/news/index.html +++ b/news/index.html @@ -40,7 +40,7 @@

diff --git a/pkgdown.yml b/pkgdown.yml index 48f6b32..befd0d5 100644 --- a/pkgdown.yml +++ b/pkgdown.yml @@ -3,7 +3,7 @@ pkgdown: 2.1.1 pkgdown_sha: ~ articles: geosimilarity: geosimilarity.html -last_built: 2024-09-29T07:38Z +last_built: 2024-09-29T07:51Z urls: reference: https://ausgis.github.io/geosimilarity/reference article: https://ausgis.github.io/geosimilarity/articles diff --git a/reference/gos.html b/reference/gos.html index daf27a7..a3a4516 100644 --- a/reference/gos.html +++ b/reference/gos.html @@ -40,7 +40,7 @@
@@ -135,7 +135,7 @@

Examples data = train, newdata = test, kappa = 0.25, cores = 1) }) #> user system elapsed -#> 0.294 0.021 0.315 +#> 0.292 0.019 0.311 test$pred <- g1$pred plot(test$Zn, test$pred) diff --git a/reference/gos_bestkappa.html b/reference/gos_bestkappa.html index cf02c41..d11fc3f 100644 --- a/reference/gos_bestkappa.html +++ b/reference/gos_bestkappa.html @@ -40,7 +40,7 @@
@@ -138,7 +138,7 @@

Examples cores = 1) }) #> user system elapsed -#> 1.299 0.002 1.300 +#> 1.290 0.003 1.294 b1$bestkappa #> [1] 1 b1$plot diff --git a/reference/grid.html b/reference/grid.html index d2958bf..3057aeb 100644 --- a/reference/grid.html +++ b/reference/grid.html @@ -40,7 +40,7 @@
diff --git a/reference/pipe.html b/reference/pipe.html index 5d8a8d0..7ad3cd5 100644 --- a/reference/pipe.html +++ b/reference/pipe.html @@ -40,7 +40,7 @@
diff --git a/reference/removeoutlier.html b/reference/removeoutlier.html index 584b136..8780238 100644 --- a/reference/removeoutlier.html +++ b/reference/removeoutlier.html @@ -40,7 +40,7 @@
diff --git a/reference/zn.html b/reference/zn.html index 56e5b97..9a1556a 100644 --- a/reference/zn.html +++ b/reference/zn.html @@ -40,7 +40,7 @@
diff --git a/search.json b/search.json index ea2b316..52f7f69 100644 --- a/search.json +++ b/search.json @@ -1 +1 @@ -[{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"citation-for-package-geosimilarity","dir":"Articles","previous_headings":"","what":"Citation for package geosimilarity","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"cite geosimilarity R package publications, please use: Song, Y. (2022) “Geographically Optimal Similarity”, Mathematical Geosciences. doi: 10.1007/s11004-022-10036-8.    ","code":""},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"introduction-to-geosimilarity-package","dir":"Articles","previous_headings":"","what":"1. Introduction to geosimilarity package","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"package can used address following issues: Geographically optimal similarity (GOS) modeling. Modeling Third Law Geography (.e., basic configuration similarity (BCS) model). Spatial prediction. details GOS models can found Song (2022).  ","code":""},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"spatial-prediction-using-gos-model","dir":"Articles","previous_headings":"","what":"2. Spatial prediction using GOS model","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"According Song (2022), GOS model consists four primary steps: (1) Characterizing geographical configurations, (2) determining parameters optimal similarity, (3) spatial prediction using GOS uncertainty assessment, (4) model evaluation. process using geosimilarity package conduct GOS modeling presented follows.","code":""},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"characterizing-geographical-configurations","dir":"Articles","previous_headings":"2. Spatial prediction using GOS model","what":"2.1 Characterizing geographical configurations","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"geosimilarity package contains two spatial datasets: zn: Spatial samples Zn concentrations explanatory variables sample locations grid: Spatial grid data explanatory variables used prediction Data pre-processing variable selection: step, selected variables include Slope, Water, NDVI, SOC, pH, Road, Mine.","code":"install.packages(\"geosimilarity\", dependencies = TRUE) library(geosimilarity) data(\"zn\") head(zn) ## # A tibble: 6 × 12 ## Lon Lat Zn Elevation Slope Aspect Water NDVI SOC pH Road Mine ## ## 1 120. -28.5 10 455. 0.236 306. 0.014 0.184 0.909 5.95 49.4 55.6 ## 2 120. -28.4 30 451. 0.207 293. 2.20 0.202 0.906 6.05 49.0 51.1 ## 3 120. -28.4 30 443. 0.285 325. 0.0119 0.163 0.848 5.76 45.1 45.0 ## 4 120. -27.4 30 509. 0.236 98.4 3.06 0.204 0.851 5.82 0.0774 49.0 ## 5 120. -28.3 33 427. 0.191 329. 3.53 0.179 0.933 5.85 39.9 39.8 ## 6 120. -27.3 27 510. 0.211 105. 3.38 0.191 0.868 6.07 0.0468 48.7 # log-transformation hist(zn$Zn) zn$Zn <- log(zn$Zn) hist(zn$Zn) # remove outliers k <- removeoutlier(zn$Zn, coef = 2.5) ## Remove 9 outlier(s) dt <- zn[-k,] # correlation library(\"PerformanceAnalytics\") ## Loading required package: xts ## Loading required package: zoo ## ## Attaching package: 'zoo' ## The following objects are masked from 'package:base': ## ## as.Date, as.Date.numeric ## ## Attaching package: 'PerformanceAnalytics' ## The following object is masked from 'package:graphics': ## ## legend cor_dt <- dt[, c(3:12)] chart.Correlation(cor_dt, histogram = TRUE, pch = 19) # multicollinearity library(car) ## Loading required package: carData m1 <- lm(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = dt) car::vif(m1) ## Slope Water NDVI SOC pH Road Mine ## 1.651039 1.232454 1.459539 1.355824 1.568347 2.273387 2.608347"},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"determining-the-optimal-similarity","dir":"Articles","previous_headings":"2. Spatial prediction using GOS model","what":"2.2 Determining the optimal similarity","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"gos_bestkappa() function, set optional numbers kappa vector higher value cross-validation repeat times nrepeat, \\(\\kappa\\) value enabling accurate prediction selected, computation time increased. can specify cores parameter use multiple CPU cores parallel computing. default ratio train set test set gos_bestkappa() 1:1(0.5). can specify ratio train set test set nsplit parameter","code":"system.time({ b1 <- gos_bestkappa(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = dt, kappa = c(0.01, 0.05, 0.1, 0.2, 0.5, 1), nrepeat = 2, cores = 1) }) ## user system elapsed ## 3.12 0.06 4.67 b1$bestkappa ## [1] 0.1 b1$cvmean ## # A tibble: 6 × 2 ## kappa rmse ## ## 1 0.01 0.681 ## 2 0.05 0.663 ## 3 0.1 0.659 ## 4 0.2 0.661 ## 5 0.5 0.664 ## 6 1 0.665 system.time({ b2 <- gos_bestkappa(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = dt, kappa = c(seq(0.01, 0.1, 0.01), seq(0.2, 1, 0.1)), nrepeat = 10, cores = 6) }) ## user system elapsed ## 0.04 0.03 16.32 b2$bestkappa ## [1] 0.08 b2$cvmean ## # A tibble: 19 × 2 ## kappa rmse ## ## 1 0.01 0.694 ## 2 0.02 0.680 ## 3 0.03 0.674 ## 4 0.04 0.672 ## 5 0.05 0.669 ## 6 0.06 0.667 ## 7 0.07 0.667 ## 8 0.08 0.667 ## 9 0.09 0.667 ## 10 0.1 0.667 ## 11 0.2 0.669 ## 12 0.3 0.671 ## 13 0.4 0.672 ## 14 0.5 0.672 ## 15 0.6 0.673 ## 16 0.7 0.673 ## 17 0.8 0.673 ## 18 0.9 0.673 ## 19 1 0.673 library(cowplot) plot_grid(b1$plot,b2$plot,nrow = 1,label_fontfamily = 'serif', labels = paste0('(',letters[1:2],')'), label_fontface = 'plain',label_size = 10, hjust = -1.5,align = 'hv')"},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"spatial-prediction","dir":"Articles","previous_headings":"2. Spatial prediction using GOS model","what":"2.3 Spatial prediction","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"addition, following codes can used plot uncertainty different \\(\\zeta\\) values.","code":"system.time({ g2 <- gos(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = dt, newdata = grid, kappa = 0.08, cores = 6) }) ## user system elapsed ## 0.05 0.03 5.60 grid$pred <- exp(g2$pred) grid$uc99 <- g2$`uncertainty99` library(ggplot2) library(viridis) ## Loading required package: viridisLite f1 = ggplot(grid, aes(x = Lon, y = Lat, fill = pred)) + geom_tile() + scale_fill_viridis(option=\"magma\", direction = -1) + coord_equal() + labs(fill='Prediction') + theme_bw() f2 = ggplot(grid, aes(x = Lon, y = Lat, fill = uc99)) + geom_tile() + scale_fill_viridis(option=\"mako\", direction = -1) + coord_equal() + labs(fill=bquote(Uncertainty~(zeta==0.99))) + theme_bw() plot_grid(f1,f2,nrow = 1,label_fontfamily = 'serif', labels = paste0('(',letters[1:2],')'), label_fontface = 'plain',label_size = 10, hjust = -1.5,align = 'hv') uc <- g2 %>% dplyr::select(dplyr::starts_with(\"uncertainty\")) %>% dplyr::bind_cols(grid[,2:3],.) %>% tidyr::pivot_longer(cols = -c(1,2), names_to = \"uncertainty\", values_to = \"value\") ggplot(uc, aes(x = Lon, y = Lat, fill = value)) + geom_tile() + scale_fill_viridis(option=\"mako\", direction = -1) + coord_equal() + facet_wrap(~ uncertainty) + labs(fill='Uncertainty') + theme_bw()"},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"model-evaluation","dir":"Articles","previous_headings":"2. Spatial prediction using GOS model","what":"2.4 Model evaluation","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"can compare model accuracy GOS various models, kriging, multivariate regression, regression kriging, random forest, BCS, etc., shown Song (2022). simple example comparing modeling accuracy BCS GOS. result, MAE BCS 0.5158 MAE GOS 0.5089, RMSE BCS 0.6599 RMSE GOS 0.6523. Compared BCS, GOS reduced 1.34% MAE 1.15% RMSE.      ","code":"set.seed(99) # split data for validation: 50% training; 50% testing split <- sample(1:nrow(dt), round(nrow(dt)*0.5)) train <- dt[split,] test <- dt[-split,] library(DescTools) ## ## Attaching package: 'DescTools' ## The following object is masked from 'package:car': ## ## Recode # BCS h1 <- gos(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = train, newdata = test, kappa = 1) MAE(test$Zn, h1$pred) ## [1] 0.5158373 RMSE(test$Zn, h1$pred) ## [1] 0.6599409 # GOS h2 <- gos(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = train, newdata = test, kappa = 0.08) MAE(test$Zn, h2$pred) ## [1] 0.5089462 RMSE(test$Zn, h2$pred) ## [1] 0.6523436"},{"path":"https://ausgis.github.io/geosimilarity/authors.html","id":null,"dir":"","previous_headings":"","what":"Authors","title":"Authors and Citation","text":"Yongze Song. Author, copyright holder. Wenbo Lv. Author, maintainer.","code":""},{"path":"https://ausgis.github.io/geosimilarity/authors.html","id":"citation","dir":"","previous_headings":"","what":"Citation","title":"Authors and Citation","text":"Yongze S (2022). “Geographically Optimal Similarity.” Mathematical Geosciences, 55(3), 295–320. ISSN 1874-8953, doi:10.1007/s11004-022-10036-8, https://doi.org/10.1007/s11004-022-10036-8.","code":"@Article{Song_2022, title = {Geographically Optimal Similarity}, author = {Song Yongze}, year = {2022}, month = {nov}, volume = {55}, number = {3}, pages = {295–320}, journal = {Mathematical Geosciences}, issn = {1874-8953}, publisher = {Springer Science and Business Media LLC}, doi = {10.1007/s11004-022-10036-8}, url = {https://doi.org/10.1007/s11004-022-10036-8}, }"},{"path":"https://ausgis.github.io/geosimilarity/index.html","id":"geosimilarity","dir":"","previous_headings":"","what":"geosimilarity | Geographically Optimal Similarity\n","title":"geosimilarity | Geographically Optimal Similarity\n","text":"Geographically Optimal Similarity Please cite geosimilarity : Song, Y. (2022). Geographically Optimal Similarity. Mathematical Geosciences,55(3), 295–320. https://doi.org/10.1007/s11004-022-10036-8. BibTeX entry LaTeX users :","code":"@Article{Song_2022, title = {Geographically Optimal Similarity}, author = {Song Yongze}, year = {2022}, month = {nov}, volume = {55}, number = {3}, pages = {295–320}, journal = {Mathematical Geosciences}, issn = {1874-8953}, publisher = {Springer Science and Business Media LLC}, doi = {10.1007/s11004-022-10036-8}, url = {https://doi.org/10.1007/s11004-022-10036-8}, }"},{"path":"https://ausgis.github.io/geosimilarity/index.html","id":"installation","dir":"","previous_headings":"","what":"Installation","title":"geosimilarity | Geographically Optimal Similarity\n","text":"Install CRAN : Install development binary version R-universe : Install development source version GitHub :","code":"install.packages(\"geosimilarity\", dep = TRUE) install.packages('geosimilarity', repos = c(\"https://ausgis.r-universe.dev\", \"https://cran.rstudio.com/\"), dep = TRUE) # install.packages(\"devtools\") devtools::install_github(\"ausgis/geosimilarity\", build_vignettes = TRUE, dep = TRUE)"},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":null,"dir":"Reference","previous_headings":"","what":"geographically optimal similarity — gos","title":"geographically optimal similarity — gos","text":"Computationally optimized function geographically optimal similarity (GOS) model","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"geographically optimal similarity — gos","text":"","code":"gos(formula, data = NULL, newdata = NULL, kappa = 0.25, cores = 1)"},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"geographically optimal similarity — gos","text":"formula formula GOS model. data data.frame tibble observation data. newdata data.frame tibble prediction variables data. kappa (optional) numeric value percentage observation locations high similarity prediction location. \\(kappa = 1 - tau\\), tau probability parameter quantile operator. default kappa 0.25, meaning 25% observations high similarity prediction location used modelling. cores (optional) Positive integer. cores > 1, parallel package cluster many cores created used. can also supply cluster object. Default 1.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"geographically optimal similarity — gos","text":"tibble made predictions uncertainties. pred GOS model prediction results uncertainty90 uncertainty 0.9 quantile uncertainty95 uncertainty 0.95 quantile uncertainty99 uncertainty 0.99 quantile uncertainty99.5 uncertainty 0.995 quantile uncertainty99.9 uncertainty 0.999 quantile uncertainty100 uncertainty 1 quantile","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":"references","dir":"Reference","previous_headings":"","what":"References","title":"geographically optimal similarity — gos","text":"Song, Y. (2022). Geographically Optimal Similarity. Mathematical Geosciences. doi: 10.1007/s11004-022-10036-8.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":"ref-examples","dir":"Reference","previous_headings":"","what":"Examples","title":"geographically optimal similarity — gos","text":"","code":"data(\"zn\") # log-transformation hist(zn$Zn) zn$Zn <- log(zn$Zn) hist(zn$Zn) # remove outliers k <- removeoutlier(zn$Zn, coef = 2.5) #> Remove 9 outlier(s) dt <- zn[-k,] # split data for validation: 70% training; 30% testing split <- sample(1:nrow(dt), round(nrow(dt)*0.7)) train <- dt[split,] test <- dt[-split,] system.time({ g1 <- gos(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = train, newdata = test, kappa = 0.25, cores = 1) }) #> user system elapsed #> 0.294 0.021 0.315 test$pred <- g1$pred plot(test$Zn, test$pred) cor(test$Zn, test$pred) #> [1] 0.5272951"},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":null,"dir":"Reference","previous_headings":"","what":"function for the best kappa parameter — gos_bestkappa","title":"function for the best kappa parameter — gos_bestkappa","text":"Computationally optimized function determining best kappa parameter optimal similarity","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"function for the best kappa parameter — gos_bestkappa","text":"","code":"gos_bestkappa( formula, data = NULL, kappa = seq(0.05, 1, 0.05), nrepeat = 10, nsplit = 0.5, cores = 1 )"},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"function for the best kappa parameter — gos_bestkappa","text":"formula formula GOS model. data data.frame tibble observation data. kappa (optional) numeric value percentage observation locations high similarity prediction location. \\(kappa = 1 - tau\\), tau probability parameter quantile operator. kappa 0.25 means 25% observations high similarity prediction location used modelling. nrepeat (optional) numeric value number cross-validation training times. default value 10. nsplit (optional) sample training set segmentation ratio,(0,1). Default 0.5. cores (optional) Positive integer. cores > 1, parallel package cluster many cores created used. can also supply cluster object. Default 1.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"function for the best kappa parameter — gos_bestkappa","text":"list. bestkappa result best kappa cvrmse RMSE calculations cross-validation cvmean average RMSE corresponding different kappa cross-validation process plot plot rmse changes corresponding different kappa","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":"references","dir":"Reference","previous_headings":"","what":"References","title":"function for the best kappa parameter — gos_bestkappa","text":"Song, Y. (2022). Geographically Optimal Similarity. Mathematical Geosciences. doi: 10.1007/s11004-022-10036-8.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":"ref-examples","dir":"Reference","previous_headings":"","what":"Examples","title":"function for the best kappa parameter — gos_bestkappa","text":"","code":"data(\"zn\") # log-transformation hist(zn$Zn) zn$Zn <- log(zn$Zn) hist(zn$Zn) # remove outliers k <- removeoutlier(zn$Zn, coef = 2.5) #> Remove 9 outlier(s) dt <- zn[-k,] # determine the best kappa system.time({ b1 <- gos_bestkappa(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = dt, kappa = c(0.01, 0.1, 1), nrepeat = 1, cores = 1) }) #> user system elapsed #> 1.299 0.002 1.300 b1$bestkappa #> [1] 1 b1$plot"},{"path":"https://ausgis.github.io/geosimilarity/reference/grid.html","id":null,"dir":"Reference","previous_headings":"","what":"Spatial grid data of explanatory variables. — grid","title":"Spatial grid data of explanatory variables. — grid","text":"Spatial grid data explanatory variables.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/grid.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Spatial grid data of explanatory variables. — grid","text":"","code":"grid"},{"path":"https://ausgis.github.io/geosimilarity/reference/grid.html","id":"format","dir":"Reference","previous_headings":"","what":"Format","title":"Spatial grid data of explanatory variables. — grid","text":"grid: tibble grided trace element explanatory variables 13132 rows 12 variables, first column ID.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/grid.html","id":"author","dir":"Reference","previous_headings":"","what":"Author","title":"Spatial grid data of explanatory variables. — grid","text":"Yongze Song yongze.song@outlook.com","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/pipe.html","id":null,"dir":"Reference","previous_headings":"","what":"Pipe operator — %>%","title":"Pipe operator — %>%","text":"See magrittr::%>% details.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/pipe.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Pipe operator — %>%","text":"","code":"lhs %>% rhs"},{"path":"https://ausgis.github.io/geosimilarity/reference/pipe.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"Pipe operator — %>%","text":"NULL (magrittr pipe operator)","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/removeoutlier.html","id":null,"dir":"Reference","previous_headings":"","what":"Removing outliers. — removeoutlier","title":"Removing outliers. — removeoutlier","text":"Function removing outliers.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/removeoutlier.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Removing outliers. — removeoutlier","text":"","code":"removeoutlier(x, coef = 2.5)"},{"path":"https://ausgis.github.io/geosimilarity/reference/removeoutlier.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Removing outliers. — removeoutlier","text":"x vector variable coef number times standard deviation. Default 2.5.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/removeoutlier.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"Removing outliers. — removeoutlier","text":"Location outliers vector","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/removeoutlier.html","id":"ref-examples","dir":"Reference","previous_headings":"","what":"Examples","title":"Removing outliers. — removeoutlier","text":"","code":"data(\"zn\") # log-transformation hist(zn$Zn) zn$Zn <- log(zn$Zn) hist(zn$Zn) # remove outliers k <- removeoutlier(zn$Zn, coef = 2.5) #> Remove 9 outlier(s) k #> [1] 180 455 460 520 551 607 645 691 813"},{"path":"https://ausgis.github.io/geosimilarity/reference/zn.html","id":null,"dir":"Reference","previous_headings":"","what":"Spatial datasets of trace element Zn. — zn","title":"Spatial datasets of trace element Zn. — zn","text":"Spatial datasets trace element Zn.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/zn.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Spatial datasets of trace element Zn. — zn","text":"","code":"zn"},{"path":"https://ausgis.github.io/geosimilarity/reference/zn.html","id":"format","dir":"Reference","previous_headings":"","what":"Format","title":"Spatial datasets of trace element Zn. — zn","text":"zn: tibble trace element Zn 894 rows 12 variables","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/zn.html","id":"author","dir":"Reference","previous_headings":"","what":"Author","title":"Spatial datasets of trace element Zn. — zn","text":"Yongze Song yongze.song@outlook.com","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-36","dir":"Changelog","previous_headings":"","what":"geosimilarity 3.6","title":"geosimilarity 3.6","text":"explicit change, updating document.","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-33","dir":"Changelog","previous_headings":"","what":"geosimilarity 3.3","title":"geosimilarity 3.3","text":"CRAN release: 2024-09-15 Fix bug executing GOS model right side formula .. Solve potential errors caused inconsistent variables arrangement training prediction data GOS model input.","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-32","dir":"Changelog","previous_headings":"","what":"geosimilarity 3.2","title":"geosimilarity 3.2","text":"CRAN release: 2024-09-08 Add removeoutlier() function. Drop Suggests dependency SecDim package. Use correct version number package attachment information.","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-31","dir":"Changelog","previous_headings":"","what":"geosimilarity 3.1","title":"geosimilarity 3.1","text":"CRAN release: 2024-08-29 Automatically loaded tibble namespace package loaded. Add citation.","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-30","dir":"Changelog","previous_headings":"","what":"geosimilarity 3.0","title":"geosimilarity 3.0","text":"CRAN release: 2024-08-21 Multi-core parallel computing support based parallel package. Rename bestkappa() function gos_bestkappa(). Add train set test set partition setting gos_bestkappa(). Intra-package case data now stored tibble format","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-22","dir":"Changelog","previous_headings":"","what":"geosimilarity 2.2","title":"geosimilarity 2.2","text":"CRAN release: 2022-11-08 First stable release.","code":""}] +[{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"citation-for-package-geosimilarity","dir":"Articles","previous_headings":"","what":"Citation for package geosimilarity","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"cite geosimilarity R package publications, please use: Song, Y. (2022) “Geographically Optimal Similarity”, Mathematical Geosciences. doi: 10.1007/s11004-022-10036-8.    ","code":""},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"introduction-to-geosimilarity-package","dir":"Articles","previous_headings":"","what":"1. Introduction to geosimilarity package","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"package can used address following issues: Geographically optimal similarity (GOS) modeling. Modeling Third Law Geography (.e., basic configuration similarity (BCS) model). Spatial prediction. details GOS models can found Song (2022).  ","code":""},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"spatial-prediction-using-gos-model","dir":"Articles","previous_headings":"","what":"2. Spatial prediction using GOS model","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"According Song (2022), GOS model consists four primary steps: (1) Characterizing geographical configurations, (2) determining parameters optimal similarity, (3) spatial prediction using GOS uncertainty assessment, (4) model evaluation. process using geosimilarity package conduct GOS modeling presented follows.","code":""},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"characterizing-geographical-configurations","dir":"Articles","previous_headings":"2. Spatial prediction using GOS model","what":"2.1 Characterizing geographical configurations","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"geosimilarity package contains two spatial datasets: zn: Spatial samples Zn concentrations explanatory variables sample locations grid: Spatial grid data explanatory variables used prediction Data pre-processing variable selection: step, selected variables include Slope, Water, NDVI, SOC, pH, Road, Mine.","code":"install.packages(\"geosimilarity\", dependencies = TRUE) library(geosimilarity) data(\"zn\") head(zn) ## # A tibble: 6 × 12 ## Lon Lat Zn Elevation Slope Aspect Water NDVI SOC pH Road Mine ## ## 1 120. -28.5 10 455. 0.236 306. 0.014 0.184 0.909 5.95 49.4 55.6 ## 2 120. -28.4 30 451. 0.207 293. 2.20 0.202 0.906 6.05 49.0 51.1 ## 3 120. -28.4 30 443. 0.285 325. 0.0119 0.163 0.848 5.76 45.1 45.0 ## 4 120. -27.4 30 509. 0.236 98.4 3.06 0.204 0.851 5.82 0.0774 49.0 ## 5 120. -28.3 33 427. 0.191 329. 3.53 0.179 0.933 5.85 39.9 39.8 ## 6 120. -27.3 27 510. 0.211 105. 3.38 0.191 0.868 6.07 0.0468 48.7 # log-transformation hist(zn$Zn) zn$Zn <- log(zn$Zn) hist(zn$Zn) # remove outliers k <- removeoutlier(zn$Zn, coef = 2.5) ## Remove 9 outlier(s) dt <- zn[-k,] # correlation library(\"PerformanceAnalytics\") ## Loading required package: xts ## Loading required package: zoo ## ## Attaching package: 'zoo' ## The following objects are masked from 'package:base': ## ## as.Date, as.Date.numeric ## ## Attaching package: 'PerformanceAnalytics' ## The following object is masked from 'package:graphics': ## ## legend cor_dt <- dt[, c(3:12)] chart.Correlation(cor_dt, histogram = TRUE, pch = 19) # multicollinearity library(car) ## Loading required package: carData m1 <- lm(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = dt) car::vif(m1) ## Slope Water NDVI SOC pH Road Mine ## 1.651039 1.232454 1.459539 1.355824 1.568347 2.273387 2.608347"},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"determining-the-optimal-similarity","dir":"Articles","previous_headings":"2. Spatial prediction using GOS model","what":"2.2 Determining the optimal similarity","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"gos_bestkappa() function, set optional numbers kappa vector higher value cross-validation repeat times nrepeat, \\(\\kappa\\) value enabling accurate prediction selected, computation time increased. can specify cores parameter use multiple CPU cores parallel computing. default ratio train set test set gos_bestkappa() 1:1(0.5). can specify ratio train set test set nsplit parameter","code":"system.time({ b1 <- gos_bestkappa(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = dt, kappa = c(0.01, 0.05, 0.1, 0.2, 0.5, 1), nrepeat = 2, cores = 1) }) ## user system elapsed ## 3.12 0.06 4.67 b1$bestkappa ## [1] 0.1 b1$cvmean ## # A tibble: 6 × 2 ## kappa rmse ## ## 1 0.01 0.681 ## 2 0.05 0.663 ## 3 0.1 0.659 ## 4 0.2 0.661 ## 5 0.5 0.664 ## 6 1 0.665 system.time({ b2 <- gos_bestkappa(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = dt, kappa = c(seq(0.01, 0.1, 0.01), seq(0.2, 1, 0.1)), nrepeat = 10, cores = 6) }) ## user system elapsed ## 0.04 0.03 16.32 b2$bestkappa ## [1] 0.08 b2$cvmean ## # A tibble: 19 × 2 ## kappa rmse ## ## 1 0.01 0.694 ## 2 0.02 0.680 ## 3 0.03 0.674 ## 4 0.04 0.672 ## 5 0.05 0.669 ## 6 0.06 0.667 ## 7 0.07 0.667 ## 8 0.08 0.667 ## 9 0.09 0.667 ## 10 0.1 0.667 ## 11 0.2 0.669 ## 12 0.3 0.671 ## 13 0.4 0.672 ## 14 0.5 0.672 ## 15 0.6 0.673 ## 16 0.7 0.673 ## 17 0.8 0.673 ## 18 0.9 0.673 ## 19 1 0.673 library(cowplot) plot_grid(b1$plot,b2$plot,nrow = 1,label_fontfamily = 'serif', labels = paste0('(',letters[1:2],')'), label_fontface = 'plain',label_size = 10, hjust = -1.5,align = 'hv')"},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"spatial-prediction","dir":"Articles","previous_headings":"2. Spatial prediction using GOS model","what":"2.3 Spatial prediction","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"addition, following codes can used plot uncertainty different \\(\\zeta\\) values.","code":"system.time({ g2 <- gos(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = dt, newdata = grid, kappa = 0.08, cores = 6) }) ## user system elapsed ## 0.05 0.03 5.60 grid$pred <- exp(g2$pred) grid$uc99 <- g2$`uncertainty99` library(ggplot2) library(viridis) ## Loading required package: viridisLite f1 = ggplot(grid, aes(x = Lon, y = Lat, fill = pred)) + geom_tile() + scale_fill_viridis(option=\"magma\", direction = -1) + coord_equal() + labs(fill='Prediction') + theme_bw() f2 = ggplot(grid, aes(x = Lon, y = Lat, fill = uc99)) + geom_tile() + scale_fill_viridis(option=\"mako\", direction = -1) + coord_equal() + labs(fill=bquote(Uncertainty~(zeta==0.99))) + theme_bw() plot_grid(f1,f2,nrow = 1,label_fontfamily = 'serif', labels = paste0('(',letters[1:2],')'), label_fontface = 'plain',label_size = 10, hjust = -1.5,align = 'hv') uc <- g2 %>% dplyr::select(dplyr::starts_with(\"uncertainty\")) %>% dplyr::bind_cols(grid[,2:3],.) %>% tidyr::pivot_longer(cols = -c(1,2), names_to = \"uncertainty\", values_to = \"value\") ggplot(uc, aes(x = Lon, y = Lat, fill = value)) + geom_tile() + scale_fill_viridis(option=\"mako\", direction = -1) + coord_equal() + facet_wrap(~ uncertainty) + labs(fill='Uncertainty') + theme_bw()"},{"path":"https://ausgis.github.io/geosimilarity/articles/geosimilarity.html","id":"model-evaluation","dir":"Articles","previous_headings":"2. Spatial prediction using GOS model","what":"2.4 Model evaluation","title":"Geographically Optimal Similarity (GOS) and the Third Law of Geography in R","text":"can compare model accuracy GOS various models, kriging, multivariate regression, regression kriging, random forest, BCS, etc., shown Song (2022). simple example comparing modeling accuracy BCS GOS. result, MAE BCS 0.5158 MAE GOS 0.5089, RMSE BCS 0.6599 RMSE GOS 0.6523. Compared BCS, GOS reduced 1.34% MAE 1.15% RMSE.      ","code":"set.seed(99) # split data for validation: 50% training; 50% testing split <- sample(1:nrow(dt), round(nrow(dt)*0.5)) train <- dt[split,] test <- dt[-split,] library(DescTools) ## ## Attaching package: 'DescTools' ## The following object is masked from 'package:car': ## ## Recode # BCS h1 <- gos(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = train, newdata = test, kappa = 1) MAE(test$Zn, h1$pred) ## [1] 0.5158373 RMSE(test$Zn, h1$pred) ## [1] 0.6599409 # GOS h2 <- gos(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = train, newdata = test, kappa = 0.08) MAE(test$Zn, h2$pred) ## [1] 0.5089462 RMSE(test$Zn, h2$pred) ## [1] 0.6523436"},{"path":"https://ausgis.github.io/geosimilarity/authors.html","id":null,"dir":"","previous_headings":"","what":"Authors","title":"Authors and Citation","text":"Yongze Song. Author, copyright holder. Wenbo Lv. Author, maintainer.","code":""},{"path":"https://ausgis.github.io/geosimilarity/authors.html","id":"citation","dir":"","previous_headings":"","what":"Citation","title":"Authors and Citation","text":"Yongze S (2022). “Geographically Optimal Similarity.” Mathematical Geosciences, 55(3), 295–320. ISSN 1874-8953, doi:10.1007/s11004-022-10036-8, https://doi.org/10.1007/s11004-022-10036-8.","code":"@Article{Song_2022, title = {Geographically Optimal Similarity}, author = {Song Yongze}, year = {2022}, month = {nov}, volume = {55}, number = {3}, pages = {295–320}, journal = {Mathematical Geosciences}, issn = {1874-8953}, publisher = {Springer Science and Business Media LLC}, doi = {10.1007/s11004-022-10036-8}, url = {https://doi.org/10.1007/s11004-022-10036-8}, }"},{"path":"https://ausgis.github.io/geosimilarity/index.html","id":"geosimilarity","dir":"","previous_headings":"","what":"geosimilarity | Geographically Optimal Similarity\n","title":"geosimilarity | Geographically Optimal Similarity\n","text":"Geographically Optimal Similarity Please cite geosimilarity : Song, Y. (2022). Geographically Optimal Similarity. Mathematical Geosciences,55(3), 295–320. https://doi.org/10.1007/s11004-022-10036-8. BibTeX entry LaTeX users :","code":"@Article{Song_2022, title = {Geographically Optimal Similarity}, author = {Song Yongze}, year = {2022}, month = {nov}, volume = {55}, number = {3}, pages = {295–320}, journal = {Mathematical Geosciences}, issn = {1874-8953}, publisher = {Springer Science and Business Media LLC}, doi = {10.1007/s11004-022-10036-8}, url = {https://doi.org/10.1007/s11004-022-10036-8}, }"},{"path":"https://ausgis.github.io/geosimilarity/index.html","id":"installation","dir":"","previous_headings":"","what":"Installation","title":"geosimilarity | Geographically Optimal Similarity\n","text":"Install CRAN : Install development binary version R-universe : Install development source version GitHub :","code":"install.packages(\"geosimilarity\", dep = TRUE) install.packages('geosimilarity', repos = c(\"https://ausgis.r-universe.dev\", \"https://cran.rstudio.com/\"), dep = TRUE) # install.packages(\"devtools\") devtools::install_github(\"ausgis/geosimilarity\", build_vignettes = TRUE, dep = TRUE)"},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":null,"dir":"Reference","previous_headings":"","what":"geographically optimal similarity — gos","title":"geographically optimal similarity — gos","text":"Computationally optimized function geographically optimal similarity (GOS) model","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"geographically optimal similarity — gos","text":"","code":"gos(formula, data = NULL, newdata = NULL, kappa = 0.25, cores = 1)"},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"geographically optimal similarity — gos","text":"formula formula GOS model. data data.frame tibble observation data. newdata data.frame tibble prediction variables data. kappa (optional) numeric value percentage observation locations high similarity prediction location. \\(kappa = 1 - tau\\), tau probability parameter quantile operator. default kappa 0.25, meaning 25% observations high similarity prediction location used modelling. cores (optional) Positive integer. cores > 1, parallel package cluster many cores created used. can also supply cluster object. Default 1.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"geographically optimal similarity — gos","text":"tibble made predictions uncertainties. pred GOS model prediction results uncertainty90 uncertainty 0.9 quantile uncertainty95 uncertainty 0.95 quantile uncertainty99 uncertainty 0.99 quantile uncertainty99.5 uncertainty 0.995 quantile uncertainty99.9 uncertainty 0.999 quantile uncertainty100 uncertainty 1 quantile","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":"references","dir":"Reference","previous_headings":"","what":"References","title":"geographically optimal similarity — gos","text":"Song, Y. (2022). Geographically Optimal Similarity. Mathematical Geosciences. doi: 10.1007/s11004-022-10036-8.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos.html","id":"ref-examples","dir":"Reference","previous_headings":"","what":"Examples","title":"geographically optimal similarity — gos","text":"","code":"data(\"zn\") # log-transformation hist(zn$Zn) zn$Zn <- log(zn$Zn) hist(zn$Zn) # remove outliers k <- removeoutlier(zn$Zn, coef = 2.5) #> Remove 9 outlier(s) dt <- zn[-k,] # split data for validation: 70% training; 30% testing split <- sample(1:nrow(dt), round(nrow(dt)*0.7)) train <- dt[split,] test <- dt[-split,] system.time({ g1 <- gos(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = train, newdata = test, kappa = 0.25, cores = 1) }) #> user system elapsed #> 0.292 0.019 0.311 test$pred <- g1$pred plot(test$Zn, test$pred) cor(test$Zn, test$pred) #> [1] 0.5272951"},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":null,"dir":"Reference","previous_headings":"","what":"function for the best kappa parameter — gos_bestkappa","title":"function for the best kappa parameter — gos_bestkappa","text":"Computationally optimized function determining best kappa parameter optimal similarity","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"function for the best kappa parameter — gos_bestkappa","text":"","code":"gos_bestkappa( formula, data = NULL, kappa = seq(0.05, 1, 0.05), nrepeat = 10, nsplit = 0.5, cores = 1 )"},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"function for the best kappa parameter — gos_bestkappa","text":"formula formula GOS model. data data.frame tibble observation data. kappa (optional) numeric value percentage observation locations high similarity prediction location. \\(kappa = 1 - tau\\), tau probability parameter quantile operator. kappa 0.25 means 25% observations high similarity prediction location used modelling. nrepeat (optional) numeric value number cross-validation training times. default value 10. nsplit (optional) sample training set segmentation ratio,(0,1). Default 0.5. cores (optional) Positive integer. cores > 1, parallel package cluster many cores created used. can also supply cluster object. Default 1.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"function for the best kappa parameter — gos_bestkappa","text":"list. bestkappa result best kappa cvrmse RMSE calculations cross-validation cvmean average RMSE corresponding different kappa cross-validation process plot plot rmse changes corresponding different kappa","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":"references","dir":"Reference","previous_headings":"","what":"References","title":"function for the best kappa parameter — gos_bestkappa","text":"Song, Y. (2022). Geographically Optimal Similarity. Mathematical Geosciences. doi: 10.1007/s11004-022-10036-8.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/gos_bestkappa.html","id":"ref-examples","dir":"Reference","previous_headings":"","what":"Examples","title":"function for the best kappa parameter — gos_bestkappa","text":"","code":"data(\"zn\") # log-transformation hist(zn$Zn) zn$Zn <- log(zn$Zn) hist(zn$Zn) # remove outliers k <- removeoutlier(zn$Zn, coef = 2.5) #> Remove 9 outlier(s) dt <- zn[-k,] # determine the best kappa system.time({ b1 <- gos_bestkappa(Zn ~ Slope + Water + NDVI + SOC + pH + Road + Mine, data = dt, kappa = c(0.01, 0.1, 1), nrepeat = 1, cores = 1) }) #> user system elapsed #> 1.290 0.003 1.294 b1$bestkappa #> [1] 1 b1$plot"},{"path":"https://ausgis.github.io/geosimilarity/reference/grid.html","id":null,"dir":"Reference","previous_headings":"","what":"Spatial grid data of explanatory variables. — grid","title":"Spatial grid data of explanatory variables. — grid","text":"Spatial grid data explanatory variables.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/grid.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Spatial grid data of explanatory variables. — grid","text":"","code":"grid"},{"path":"https://ausgis.github.io/geosimilarity/reference/grid.html","id":"format","dir":"Reference","previous_headings":"","what":"Format","title":"Spatial grid data of explanatory variables. — grid","text":"grid: tibble grided trace element explanatory variables 13132 rows 12 variables, first column ID.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/grid.html","id":"author","dir":"Reference","previous_headings":"","what":"Author","title":"Spatial grid data of explanatory variables. — grid","text":"Yongze Song yongze.song@outlook.com","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/pipe.html","id":null,"dir":"Reference","previous_headings":"","what":"Pipe operator — %>%","title":"Pipe operator — %>%","text":"See magrittr::%>% details.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/pipe.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Pipe operator — %>%","text":"","code":"lhs %>% rhs"},{"path":"https://ausgis.github.io/geosimilarity/reference/pipe.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"Pipe operator — %>%","text":"NULL (magrittr pipe operator)","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/removeoutlier.html","id":null,"dir":"Reference","previous_headings":"","what":"Removing outliers. — removeoutlier","title":"Removing outliers. — removeoutlier","text":"Function removing outliers.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/removeoutlier.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Removing outliers. — removeoutlier","text":"","code":"removeoutlier(x, coef = 2.5)"},{"path":"https://ausgis.github.io/geosimilarity/reference/removeoutlier.html","id":"arguments","dir":"Reference","previous_headings":"","what":"Arguments","title":"Removing outliers. — removeoutlier","text":"x vector variable coef number times standard deviation. Default 2.5.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/removeoutlier.html","id":"value","dir":"Reference","previous_headings":"","what":"Value","title":"Removing outliers. — removeoutlier","text":"Location outliers vector","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/removeoutlier.html","id":"ref-examples","dir":"Reference","previous_headings":"","what":"Examples","title":"Removing outliers. — removeoutlier","text":"","code":"data(\"zn\") # log-transformation hist(zn$Zn) zn$Zn <- log(zn$Zn) hist(zn$Zn) # remove outliers k <- removeoutlier(zn$Zn, coef = 2.5) #> Remove 9 outlier(s) k #> [1] 180 455 460 520 551 607 645 691 813"},{"path":"https://ausgis.github.io/geosimilarity/reference/zn.html","id":null,"dir":"Reference","previous_headings":"","what":"Spatial datasets of trace element Zn. — zn","title":"Spatial datasets of trace element Zn. — zn","text":"Spatial datasets trace element Zn.","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/zn.html","id":"ref-usage","dir":"Reference","previous_headings":"","what":"Usage","title":"Spatial datasets of trace element Zn. — zn","text":"","code":"zn"},{"path":"https://ausgis.github.io/geosimilarity/reference/zn.html","id":"format","dir":"Reference","previous_headings":"","what":"Format","title":"Spatial datasets of trace element Zn. — zn","text":"zn: tibble trace element Zn 894 rows 12 variables","code":""},{"path":"https://ausgis.github.io/geosimilarity/reference/zn.html","id":"author","dir":"Reference","previous_headings":"","what":"Author","title":"Spatial datasets of trace element Zn. — zn","text":"Yongze Song yongze.song@outlook.com","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-36","dir":"Changelog","previous_headings":"","what":"geosimilarity 3.6","title":"geosimilarity 3.6","text":"explicit change, updating document.","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-33","dir":"Changelog","previous_headings":"","what":"geosimilarity 3.3","title":"geosimilarity 3.3","text":"CRAN release: 2024-09-15 Fix bug executing GOS model right side formula .. Solve potential errors caused inconsistent variables arrangement training prediction data GOS model input.","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-32","dir":"Changelog","previous_headings":"","what":"geosimilarity 3.2","title":"geosimilarity 3.2","text":"CRAN release: 2024-09-08 Add removeoutlier() function. Drop Suggests dependency SecDim package. Use correct version number package attachment information.","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-31","dir":"Changelog","previous_headings":"","what":"geosimilarity 3.1","title":"geosimilarity 3.1","text":"CRAN release: 2024-08-29 Automatically loaded tibble namespace package loaded. Add citation.","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-30","dir":"Changelog","previous_headings":"","what":"geosimilarity 3.0","title":"geosimilarity 3.0","text":"CRAN release: 2024-08-21 Multi-core parallel computing support based parallel package. Rename bestkappa() function gos_bestkappa(). Add train set test set partition setting gos_bestkappa(). Intra-package case data now stored tibble format","code":""},{"path":"https://ausgis.github.io/geosimilarity/news/index.html","id":"geosimilarity-22","dir":"Changelog","previous_headings":"","what":"geosimilarity 2.2","title":"geosimilarity 2.2","text":"CRAN release: 2022-11-08 First stable release.","code":""}]