mirror of
https://github.com/agdamsbo/FreesearchR.git
synced 2025-12-16 17:42:10 +01:00
29 lines
344 B
Markdown
29 lines
344 B
Markdown
|
|
# Checks if elements in vector are equally spaced as indication of ID
|
||
|
|
|
||
|
|
Checks if elements in vector are equally spaced as indication of ID
|
||
|
|
|
||
|
|
## Usage
|
||
|
|
|
||
|
|
``` r
|
||
|
|
is_consecutive(data)
|
||
|
|
```
|
||
|
|
|
||
|
|
## Arguments
|
||
|
|
|
||
|
|
- data:
|
||
|
|
|
||
|
|
vector
|
||
|
|
|
||
|
|
## Value
|
||
|
|
|
||
|
|
logical
|
||
|
|
|
||
|
|
## Examples
|
||
|
|
|
||
|
|
``` r
|
||
|
|
1:10 |> is_consecutive()
|
||
|
|
#> [1] TRUE
|
||
|
|
sample(1:100,40) |> is_consecutive()
|
||
|
|
#> [1] FALSE
|
||
|
|
```
|