Skip to content

Commit

Permalink
suppress warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
SpatLyu committed Jun 18, 2024
1 parent 3d9a299 commit 5861486
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 16 deletions.
5 changes: 3 additions & 2 deletions R/discretization.R
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,9 @@ st_unidisc = \(x,k,method = "quantile",factor = FALSE,
seed = 12345678,...){
if (k<=2) {stop(" `k` must greater than 3 !")}
set.seed(seed)
return(classInt::classify_intervals(var = x,n = k - 1,style = method,
...,factor = factor))
return(suppressWarnings(classInt::classify_intervals(var = x,n = k - 1,
style = method,
...,factor = factor)))
}

#' @title best univariate discretization based on geodetector q-statistic
Expand Down
9 changes: 3 additions & 6 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,18 @@ knitr::opts_chunk$set(
[![r-universe](https://spatlyu.r-universe.dev/badges/gdverse)](https://spatlyu.r-universe.dev/gdverse)
<!-- badges: end -->

The goal of gdverse is to support the geodetector model and its variants.
The goal of **gdverse** is to *support the geodetector model and its variants*.

## Installation

You can install the development version of gdverse from [GitHub](https://github.com/SpatLyu/gdverse) with:
You can install the development version of **gdverse** from [github](https://github.com/SpatLyu/gdverse) with:

``` r
# install.packages("devtools")
devtools::install_github("SpatLyu/gdverse",build_vignettes = T,dep = T)
```

or install `gdverse` from `r-universe`:
or install **gdverse** from [r-universe](https://spatlyu.r-universe.dev/gdverse):

```r
install.packages('gdverse', repos='https://spatlyu.r-universe.dev')
Expand All @@ -42,7 +42,6 @@ install.packages('gdverse', repos='https://spatlyu.r-universe.dev')
### Load data and package

```{r example_gdverse}
library(sf)
library(terra)
library(tidyverse)
library(gdverse)
Expand All @@ -67,9 +66,7 @@ fvc_opgd
### GOZH model

```{r}
tictoc::tic()
g = gozh(fvc ~ ., data = fvc, cores = 6)
tictoc::tic()
g
```

Expand Down
12 changes: 4 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,22 +9,20 @@
[![r-universe](https://spatlyu.r-universe.dev/badges/gdverse)](https://spatlyu.r-universe.dev/gdverse)
<!-- badges: end -->

The goal of gdverse is to support the geodetector model and its
variants.
The goal of **gdverse** is to *support the geodetector model and its variants*.

## Installation

You can install the development version of gdverse from
[GitHub](https://github.com/SpatLyu/gdverse) with:
You can install the development version of **gdverse** from [github](https://github.com/SpatLyu/gdverse) with:

``` r
# install.packages("devtools")
devtools::install_github("SpatLyu/gdverse",build_vignettes = T,dep = T)
```

or install `gdverse` from `r-universe`:
or install **gdverse** from [r-universe](https://spatlyu.r-universe.dev/gdverse):

``` r
```r
install.packages('gdverse', repos='https://spatlyu.r-universe.dev')
```

Expand Down Expand Up @@ -88,9 +86,7 @@ fvc_opgd
### GOZH model

``` r
tictoc::tic()
g = gozh(fvc ~ ., data = fvc, cores = 6)
tictoc::tic()
g
## Spatial Stratified Heterogeneity Test
##
Expand Down
3 changes: 3 additions & 0 deletions vignettes/precompile.R
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,6 @@ knitr::knit("vignettes/OPGD.Rmd.orig",

knitr::knit("vignettes/RGD.Rmd.orig",
"vignettes/RGD.Rmd")

# knitr::knit("./README.Rmd",
# "./README.md")

0 comments on commit 5861486

Please sign in to comment.