From 8f50d434bbaa4729543e5be5df2ce63f6304953b Mon Sep 17 00:00:00 2001 From: SpatLyu Date: Tue, 24 Sep 2024 20:34:08 +0800 Subject: [PATCH] update rid document --- R/rid.R | 6 +++--- man/rid.Rd | 7 +++---- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/R/rid.R b/R/rid.R index cb1ed642..7ffcf852 100644 --- a/R/rid.R +++ b/R/rid.R @@ -7,7 +7,6 @@ #' A case of road life expectancy analysis. Spatial Statistics, 59(100814), 100814. #' https://doi.org/10.1016/j.spasta.2024.100814 #' @note -#' For bivariate spatial interactions, use the `RGD` function and specify the `type` parameter as `interaction`. #' #' The RID model requires at least \eqn{2^n-1} calculations when has \eqn{n} explanatory variables. #' When there are more than 10 explanatory variables, carefully consider the computational burden of this model. @@ -39,8 +38,9 @@ #' \dontrun{ #' ## The following code needs to configure the Python environment to run: #' data('sim') -#' g = rid(y ~ ., data = sim %>% dplyr::select(-dplyr::any_of(c('lo','la'))), -#' discvar = c("xa","xb","xc"), discnum = 4, cores = 6) +#' g = rid(y ~ ., +#' data = dplyr::select(sim,-dplyr::any_of(c('lo','la'))), +#' discnum = 4, cores = 6) #' g #' } rid = \(formula, data, discvar = NULL, discnum = 10, diff --git a/man/rid.Rd b/man/rid.Rd index d624a3dd..744d9ef1 100644 --- a/man/rid.Rd +++ b/man/rid.Rd @@ -43,8 +43,6 @@ A list of the RID model result. Function for robust interaction detector(RID) model. } \note{ -For bivariate spatial interactions, use the \code{RGD} function and specify the \code{type} parameter as \code{interaction}. - The RID model requires at least \eqn{2^n-1} calculations when has \eqn{n} explanatory variables. When there are more than 10 explanatory variables, carefully consider the computational burden of this model. When there are a large number of explanatory variables, the data dimensionality reduction method can be used @@ -57,8 +55,9 @@ See \code{vignette('rgdrid',package = 'gdverse')} for more details. \dontrun{ ## The following code needs to configure the Python environment to run: data('sim') -g = rid(y ~ ., data = sim \%>\% dplyr::select(-dplyr::any_of(c('lo','la'))), - discvar = c("xa","xb","xc"), discnum = 4, cores = 6) +g = rid(y ~ ., + data = dplyr::select(sim,-dplyr::any_of(c('lo','la'))), + discnum = 4, cores = 6) g } }