tests/testthat/test_shuffle_sequences.R

context("shuffle_sequences()")

test_that("sequence shuffling works", {

  seqs <- create_sequences()
  s <- shuffle_sequences(seqs)
  l <- shuffle_sequences(seqs, method = "linear", k = 2)
  m <- shuffle_sequences(seqs, method = "markov", k = 2)

  expect_s4_class(seqs, "DNAStringSet")
  expect_true(any(s != l))
  expect_true(any(s != m))
  expect_true(any(l != m))

})

Try the universalmotif package in your browser

Any scripts or data that you put into this service are public.

universalmotif documentation built on April 8, 2021, 6 p.m.