Code
(expect_error(iv_locate_overlaps(iv(1, 2), iv("a", "b"))))
Output
<error/vctrs_error_ptype2>
Error in `iv_locate_overlaps()`:
! Can't combine `needles` <double> and `haystack` <character>.
Code
(expect_error(iv_locate_overlaps(iv(NA, NA), iv(1, 2), missing = "error")))
Output
<error/vctrs_error_matches_incomplete>
Error in `iv_locate_overlaps()`:
! `needles` can't contain missing values.
x Location 1 contains missing values.
Code
(expect_error(iv_locate_overlaps(x, y, relationship = "many-to-one")))
Output
<error/vctrs_error_matches_relationship_many_to_one>
Error in `iv_locate_overlaps()`:
! Each value of `needles` can match at most 1 value from `haystack`.
x Location 1 of `needles` matches multiple values.
Code
(expect_error(iv_count_overlaps(iv(NA, NA), iv(1, 2), missing = "error")))
Output
<error/vctrs_error_matches_incomplete>
Error in `iv_locate_overlaps()`:
! `needles` can't contain missing values.
x Location 1 contains missing values.
type
Code
iv_overlaps(iv(1, 2), iv(1, 2), type = "foo")
Condition
Error in `iv_overlaps()`:
! `type` must be one of "any", "equals", "contains", "within", "starts", or "ends", not "foo".
Code
(expect_error(iv_locate_precedes(iv(1, 2), iv("a", "b"))))
Output
<error/vctrs_error_ptype2>
Error in `iv_locate_precedes()`:
! Can't combine `needles` <double> and `haystack` <character>.
Code
(expect_error(iv_locate_precedes(iv(1, 2), iv(1, 2), closest = "x")))
Output
<error/rlang_error>
Error in `iv_locate_precedes()`:
! `closest` must be a single `TRUE` or `FALSE`.
Code
(expect_error(iv_locate_precedes(iv(NA, NA), iv(1, 2), missing = "error")))
Output
<error/vctrs_error_matches_incomplete>
Error in `iv_locate_precedes()`:
! `needles` can't contain missing values.
x Location 1 contains missing values.
Code
(expect_error(iv_locate_precedes(x, y, relationship = "many-to-one")))
Output
<error/vctrs_error_matches_relationship_many_to_one>
Error in `iv_locate_precedes()`:
! Each value of `needles` can match at most 1 value from `haystack`.
x Location 1 of `needles` matches multiple values.
Code
(expect_error(iv_locate_precedes(x, y, relationship = "many-to-one", closest = TRUE))
)
Output
<error/vctrs_error_matches_relationship_many_to_one>
Error in `iv_locate_precedes()`:
! Each value of `needles` can match at most 1 value from `haystack`.
x Location 1 of `needles` matches multiple values.
Code
(expect_error(iv_locate_relates(iv(1, 2), iv("a", "b"))))
Output
<error/vctrs_error_ptype2>
Error in `iv_locate_relates()`:
! Can't combine `needles` <double> and `haystack` <character>.
Code
(expect_error(iv_locate_relates(iv(NA, NA), iv(1, 2), type = "equals", missing = "error"))
)
Output
<error/vctrs_error_matches_incomplete>
Error in `iv_locate_relates()`:
! `needles` can't contain missing values.
x Location 1 contains missing values.
Code
(expect_error(iv_locate_relates(x, y, type = "overlaps", relationship = "many-to-one"))
)
Output
<error/vctrs_error_matches_relationship_many_to_one>
Error in `iv_locate_relates()`:
! Each value of `needles` can match at most 1 value from `haystack`.
x Location 1 of `needles` matches multiple values.
Code
(expect_error(iv_count_relates(iv(NA, NA), iv(1, 2), type = "equals", missing = "error"))
)
Output
<error/vctrs_error_matches_incomplete>
Error in `iv_locate_relates()`:
! `needles` can't contain missing values.
x Location 1 contains missing values.
type
Code
iv_relates(iv(1, 2), iv(1, 2), type = "foo")
Condition
Error in `iv_relates()`:
! `type` must be one of "precedes", "preceded-by", "meets", "met-by", "overlaps", "overlapped-by", "starts", "started-by", "finishes", "finished-by", "during", "contains", or "equals", not "foo".
Code
(expect_error(iv_overlaps(iv(1, 2), iv("a", "b"))))
Output
<error/vctrs_error_ptype2>
Error in `iv_overlaps()`:
! Can't combine `needles` <double> and `haystack` <character>.
Code
(expect_error(iv_overlaps(iv(1, 2), iv(1, 2), missing = 1)))
Output
<error/rlang_error>
Error in `iv_overlaps()`:
! `missing` must be "equals", "error", or a single logical value.
Code
(expect_error(iv_overlaps(iv(1, 2), iv(1, 2), missing = "x")))
Output
<error/rlang_error>
Error in `iv_overlaps()`:
! `missing` must be "equals", "error", or a single logical value.
Code
(expect_error(iv_overlaps(iv(1, 2), iv(1, 2), missing = c(TRUE, FALSE))))
Output
<error/rlang_error>
Error in `iv_overlaps()`:
! `missing` must be "equals", "error", or a single logical value.
Code
(expect_error(iv_overlaps(iv(NA, NA), iv(1, 2), missing = "error")))
Output
<error/vctrs_error_matches_incomplete>
Error in `iv_overlaps()`:
! `needles` can't contain missing values.
x Location 1 contains missing values.
Code
(expect_error(iv_pairwise_overlaps(iv(1:2, 2:3), iv(1:3, 2:4))))
Output
<error/vctrs_error_incompatible_size>
Error in `iv_pairwise_overlaps()`:
! Can't recycle `x` (size 2) to match `y` (size 3).
Code
(expect_error(iv_pairwise_overlaps(iv(1, 2), iv("a", "b"))))
Output
<error/vctrs_error_ptype2>
Error in `iv_pairwise_overlaps()`:
! Can't combine `x` <double> and `y` <character>.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.