paf2coords | R Documentation |
This function takes loaded PAF alignments using readPaf
function. Such alignment could be post-processed
using filterPaf
, breakPaf
and flipPaf
functions. Subsequently such alignments are
expanded in a set of x and y coordinates ready to be plotted by geom_miropeats
function.
paf2coords(
paf.table,
offset.alignments = FALSE,
sync.x.coordinates = TRUE,
q.range = NULL,
t.range = NULL,
add.col = NULL
)
paf.table |
A |
offset.alignments |
Set to |
sync.x.coordinates |
If set to |
q.range |
A |
t.range |
A |
add.col |
A user defined column name present in 'paf.table' to be added in returned coordinates table. |
A tibble
of PAF alignments reported as x and y coordinate values.
David Porubsky
## Get PAF to process ##
paf.file <- system.file("extdata", "test1.paf", package = "SVbyEye")
## Read in PAF
paf.table <- readPaf(paf.file = paf.file, include.paf.tags = TRUE, restrict.paf.tags = "cg")
## Convert PAF alignments to x and y coordinates needed for plotting
paf2coords(paf.table = paf.table)
## Include optional an column to be exported as well (e.g. alignment specific GC content)
paf.table$GC.content <- round(runif(nrow(paf.table), min = 30, max = 60), digits = 2)
paf2coords(paf.table = paf.table, add.col = "GC.content")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.