LocARNA-1.9.2
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends
Classes | Public Types | Public Member Functions
LocARNA::BasePairs Class Reference

Describes sequence and structure ensemble of an RNA. More...

#include <basepairs.hh>

List of all members.

Classes

class  LeftAdjEntry
 Entry in a left adjacency list. More...
class  RightAdjEntry
 Entry in a right adjacency list. More...

Public Types

typedef size_t size_type
 size
typedef BasePairs__Arc Arc
 arc
typedef std::vector< Arcarc_vec_t
 Vector of arcs.
typedef std::vector< LeftAdjEntryLeftAdjList
 type of left adjacency list
typedef std::vector
< RightAdjEntry
RightAdjList
 type of right adjacency list
typedef SparseMatrix< int > arc_matrix_t
 type for matrix of arcs (actually arc indices)
typedef std::pair< size_type,
size_type
bpair_t
 type for pair of positions (base pairs)
typedef std::set< bpair_tbpair_set_t
 type for set of position pairs

Public Member Functions

 BasePairs (const RnaData *rna_data, double min_prob)
 BasePairs (size_type len, const bpair_set_t &bps)
 Construct from a set of base pairs.
void register_arc (int i, int j)
 Copy constructor.
const LeftAdjListleft_adjlist (int i) const
 returns the list of arcs with right end i
const RightAdjListright_adjlist (int i) const
 returns the list of arcs with left end i
const Arcarc (int i, int j) const
 accesses basepair by (i,j)
const Arcarc (size_type idx) const
bool exists_arc (int i, int j) const
 returns whether basepair (i,j) exists
size_type num_bps () const
 returns number of basepairs in the object
size_type seqlen () const
 returns length of sequence
double prob_min () const
 return minimal probability

Detailed Description

Describes sequence and structure ensemble of an RNA.

Stores and maintains the list of potential base pairs together with their score contributions in arc matches.

In contrast to RnaData, which stores the raw data for an RNA, a BasePairs object knows about sparsification of base pairs by a probability threshold and provides traversal of base pairs suited for alignment algorithms.

If the base pairs object is constructed from an RnaData object, it knows about its corresponding RnaData object.


Constructor & Destructor Documentation

LocARNA::BasePairs::BasePairs ( const RnaData rna_data,
double  min_prob 
) [inline]

Construct from rna data

Parameters:
rna_datarna data
min_probminimal probability for filtering base pairs
Note:
while rna data maintains base pairs regardless of their probability, an object of BasePairs represents the sparsified set of base pairs (due to min_prob_)
LocARNA::BasePairs::BasePairs ( size_type  len,
const bpair_set_t bps 
) [inline]

Construct from a set of base pairs.

Parameters:
lenlength of sequence
bpsset of base pairs

Member Function Documentation

const Arc& LocARNA::BasePairs::arc ( size_type  idx) const [inline]
Parameters:
idxan arc index
Returns:
arc with index idx
void LocARNA::BasePairs::register_arc ( int  i,
int  j 
)

Copy constructor.

registers an arc (i,j)

Assignment operator registers a basepair (i,j), maintains the basepair access data structures


The documentation for this class was generated from the following files:
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends