rnabioco / valr

Genome Interval Arithmetic in R
http://rnabioco.github.io/valr/
Other
88 stars 25 forks source link

bed_random doesn't return tibble if sorted = FALSE #369

Closed jayhesselberth closed 4 years ago

jayhesselberth commented 4 years ago

Not a big deal, but generates a long output on the website.

https://rnabioco.github.io/valr/reference/bed_random.html

library(valr)

genome <- tibble::tribble(
  ~chrom,  ~size,
  "chr1",  1e6,
)

class(bed_random(genome, seed = 1))
#> [1] "tbl_df"     "tbl"        "data.frame"

# not a tibble
class(bed_random(genome, sorted = FALSE, seed = 1))
#> [1] "data.frame"

Created on 2020-05-09 by the reprex package (v0.3.0)