Nothing
context("Convert map list to data frame")
test_that("map_list_to_df works", {
map_list <- list(`1` = c(JAX00240989 = 0.424118388815167, JAX00240649 = 0.041241020125091,
UNCJPD009180 = 0.466051450603133, JAX00240804 = 0.0654810203913158,
JAX00240610 = 0.0241660935186957),
`2` = c(UNCHS003854 = 0.182846980321827, UNCHS003852 = 0.182407517001796,
UNCHS003846 = 0.130917988391064, JAX00482049 = 0.000412833594312019,
JAX00482064 = 0.000640569383198255),
`10` = c(JAX00281864 = 0.0163163877989646, ICR260 = 0.00740695778637858,
JAX00014570 = 0.0124106069176088, JAX00281798 = 0.0203760400795549,
ICR4249 = 0.0208142757155046),
X = c(JAX00708681 = 0.827432787823843, JAX00708630r = 0.235740657791282,
UNCHS048201 = 0.397500188730613, JAX00176676 = 0.0507409752570731,
UNCHS048205 = 0.501406880974154))
attr(map_list, "is_x_chr") <- c("1"=FALSE, "2"=FALSE, "10"=FALSE, "X"=TRUE)
expected <- structure(list(chr = c("1", "1", "1", "1", "1", "2", "2", "2",
"2", "2", "10", "10", "10", "10", "10", "X", "X", "X", "X", "X"),
cM = c(0.424118388815167, 0.041241020125091, 0.466051450603133,
0.0654810203913158, 0.0241660935186957, 0.182846980321827, 0.182407517001796,
0.130917988391064, 0.000412833594312019, 0.000640569383198255,
0.0163163877989646, 0.00740695778637858, 0.0124106069176088,
0.0203760400795549, 0.0208142757155046, 0.827432787823843, 0.235740657791282,
0.397500188730613, 0.0507409752570731, 0.501406880974154),
marker = c("JAX00240989", "JAX00240649", "UNCJPD009180", "JAX00240804", "JAX00240610",
"UNCHS003854", "UNCHS003852", "UNCHS003846", "JAX00482049", "JAX00482064",
"JAX00281864", "ICR260", "JAX00014570", "JAX00281798", "ICR4249",
"JAX00708681", "JAX00708630r", "UNCHS048201", "JAX00176676",
"UNCHS048205")),
class = "data.frame",
row.names = c("JAX00240989", "JAX00240649", "UNCJPD009180", "JAX00240804", "JAX00240610",
"UNCHS003854", "UNCHS003852", "UNCHS003846", "JAX00482049", "JAX00482064",
"JAX00281864", "ICR260", "JAX00014570", "JAX00281798", "ICR4249",
"JAX00708681", "JAX00708630r", "UNCHS048201", "JAX00176676",
"UNCHS048205"))
expect_equal(map_list_to_df(map_list, pos_column="cM"), expected)
expect_equal(map_df_to_list( map_list_to_df(map_list, pos_column="cM"), pos_column="cM"), map_list)
})
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.