print.alignment {SeqAlignR} | R Documentation |
Prints the alignments between seq1
and seq2
with the highest score.
## S3 method for class 'alignment'
print(x, ...)
x |
Object of class |
... |
Additional parameters to be passed to the |
The printed message includes the alignment score. This function may display multiple alignments, as alignments with the same score are possible.
Console print of alignments.
seq1 <- "GCATGCG"
seq2 <- "GATTACA"
# Run the Needleman-Wunsch algorithm
alignment1 <- align_sequences(seq1, seq2, d = -1, mismatch = -1, match = 1)
# Print the alignments
print(alignment1)