Forced alignment by increasing gap open penalty
Usage
force_align(
read,
reference,
force_overhang = FALSE,
match_score = 2L,
mismatch_penalty = 2L
)
Arguments
- read
The read, character string
- reference
The reference, character string
- force_overhang
Make sure only one end overhangs?
- match_score
For scoring matches, integer
- mismatch_penalty
For scoring mismatches, integer
Value
A list containing the input sequences, ssw aligner object,
and the alignment results.
Examples
# results are truncated
a <- force_align("ACTG", "TTTTCTGCCCCCACG")
a
# format the results
b <- a %>% formatter()
b
#> [[1]]
#> [1] "TTTTCTGCCCCCACG"
#>
#> [[2]]
#> [1] " ACTG"
#>
# print the formatted results directly
a %>% formatter(print = TRUE)