Skip to content

Commit 62db63d

Browse files
Merge pull request #989 from IndrajeetPatil/rm_unused_odd_even
Remove unused internal utilities
2 parents f8ae282 + 651455f commit 62db63d

File tree

2 files changed

+2
-11
lines changed

2 files changed

+2
-11
lines changed

NEWS.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,8 @@ editor_options:
5050

5151
**Other**
5252

53+
- Non-exported and unused functions `odd()` and `even()` were removed
54+
(\@IndrajeetPatil, #989).
5355
- Old (and outdated) vignettes have been removed (\@IndrajeetPatil, #955). To
5456
access them, do `git checkout v1.0.0`.
5557
- Upgrade testing infra to testthat 3e (\@IndrajeetPatil, #949).

R/utils.R

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -48,24 +48,13 @@ two_cols_match <- function(col1, col2, data) {
4848
all(unlist(data[col1]) == unlist(data[col2]))
4949
}
5050

51-
odd <- function(x) {
52-
x[odd_index(x)]
53-
}
54-
5551
odd_index <- function(x) {
5652
if (length(x) < 1) {
5753
return(NULL)
5854
}
5955
seq(1L, length(x), by = 2)
6056
}
6157

62-
even <- function(x) {
63-
if (length(x) < 2) {
64-
return(NULL)
65-
}
66-
x[even_index(x)]
67-
}
68-
6958
even_index <- function(x) {
7059
seq(2L, length(x), by = 2)
7160
}

0 commit comments

Comments
 (0)