findPairedBases {ncRNAtools} | R Documentation |
Determines bases that form pairs in a given RNA sequence from the secondary structure string of the RNA sequence.
findPairedBases(secondaryStructureString, sequence)
secondaryStructureString |
A string representing the secondary structure of the RNA sequence in the Dot-Bracket format. |
sequence |
string with the RNA sequence corresponding to the provided secondary structure string. Should contain only standard RNA symbols (i.e., "A", "U", "G" and "C"). |
A dataframe where each row denotes a base pair. The dataframe comprises the following 4 columns:
Position1 |
position in the sequence of the nucleotide involved in the base pair closest to the 5' end of the RNA. |
Position2 |
position in the sequence of the nucleotide involved in the base pair closest to the 3' end of the RNA. |
Nucleotide1 |
nucleotide type of the base in Position1. |
Nucleotide2 |
nucleotide type of the base in Position2. |
# Read a Dot Bracket file with the secondary structure of an RNA sequence: exampleDotBracketFile <- system.file("extdata", "exampleDotBracket.dot", package="ncRNAtools") exampleDotBracket <- readDotBracket(exampleDotBracketFile) # Generate a dataframe of paired bases from the returned secondary structure # string: pairedBasesTable <- findPairedBases(secondaryStructureString=exampleDotBracket$secondaryStructure, sequence=exampleDotBracket$sequence)