A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://www.ncbi.nlm.nih.gov/IEB/ToolBox/CPP_DOC/doxyhtml/splign__exon__trim_8cpp_source.html below:

NCBI C++ ToolKit: src/algo/align/splign/splign_exon_trim.cpp Source File

48  size_t len

= segments.size();

50  for

( ; np <

len

; ++np) {

51  if

( segments[np].m_exon )

break

;

56  if

( segments[p].m_box[3] + 1 == segments[np].m_box[2] ) {

66  for

( ; pp>=0; --pp ) {

67  if

( segments[pp].m_exon )

break

;

72  if

( segments[pp].m_box[3] + 1 == segments[p].m_box[2] ) {

83  const size_t

min_query_size = 4;

84  if

(

int

(s.

m_box

[1] - s.

m_box

[0] + 1) <

int

(min_query_size)) {

107  if

( p1 >= segments.size() )

return

;

108  if

( p2 >= segments.size() )

return

;

109  if

( !segments[p1].m_exon )

return

;

110  if

( !segments[p2].m_exon )

return

;

111  size_t

pos1 =

min

( p1, p2);

112  size_t

pos2 =

max

( p1, p2);

113  if

( segments[pos1].m_box[1] >= segments[pos2].m_box[0] ||

114

segments[pos1].m_box[3] >= segments[pos2].m_box[2] ) {

121  for

(

size_t

pos = 0; pos < pos1; ++pos) {

122

new_segments.push_back(segments[pos]);

125  TSeg

s(segments[pos1]);

126

s.

m_box

[1] = segments[pos2].m_box[1];

127

s.

m_box

[3] = segments[pos2].m_box[3];

128  if

( segments[pos1].m_box[1] + 1 < segments[pos2].m_box[0]) {

129

s.

m_details

.append(segments[pos2].m_box[0] - segments[pos1].m_box[1] - 1,

'D'

);

131  if

( segments[pos1].m_box[3] + 1 < segments[pos2].m_box[2]) {

132

s.

m_details

.append(segments[pos2].m_box[2] - segments[pos1].m_box[3] - 1,

'I'

);

134

s.

m_details

+= segments[pos2].m_details;

136

new_segments.push_back(s);

138  for

(

size_t

pos = ++pos2; pos < segments.size(); ++pos) {

139

new_segments.push_back(segments[pos]);

142

segments.swap(new_segments);

150  if

( mrna_bio_handle ) {

152

vector<TSeqRange> tr;

154  for

(

CSeq_loc_CI

slit(ci->GetLocation()); slit; ++slit) {

156

ori = slit.GetRange();

160  r

.SetFrom(mrna_len - ori.

GetTo

() - 1);

161  r

.SetTo(mrna_len - ori.

GetFrom

() - 1);

167  if

(tr.empty())

return

;

171  size_t

pos1 = 0, pos2 = 2;

172  for

(; pos2 < segments.size(); ++pos1, ++pos2) {

173  if

( segments[pos1].m_exon && !segments[pos1+1].m_exon && segments[pos2].m_exon ) {

176  size_t

p1 = segments[pos1].m_box[1];

177  ITERATE

(vector<TSeqRange>, it, tr) {

178  if

( p1 >= it->GetFrom() && p1 <= it->GetTo() ) {

179  size_t

cut_mrna_len = (p1 + 1 - it->GetFrom()) % 3,

cnt

= 0;

180  string

transcript = segments[pos1].m_details;

181  int i

= (

int

)transcript.size() - 1;

182  for

(;

i

>=0; --

i

) {

183  if

(

cnt

%3 == cut_mrna_len && transcript[

i

] ==

'M'

) {

187  if

( transcript[

i

] !=

'I'

) ++

cnt

;

197  size_t

p2 = segments[pos2].m_box[0];

198  ITERATE

(vector<TSeqRange>, it, tr) {

199  if

( p2 >= it->GetFrom() && p2 <= it->GetTo() ) {

200  size_t

cut_mrna_len = ( 3 - ( p2 - it->GetFrom()) % 3 ) %3,

cnt

= 0;

201  string

transcript = segments[pos2].m_details;

203  for

( ;

i

< (

int

)transcript.size(); ++

i

) {

204  if

(

cnt

%3 == cut_mrna_len && transcript[

i

] ==

'M'

) {

208  if

( transcript[

i

] !=

'I'

) ++

cnt

;

210  if

(

i

== (

int

)transcript.size() ) {

231  if

( s.

m_box

[2] > 1 ) {

234  if

( s.

m_box

[2] > 0 ) {

264  int

gap_start_idx (-1);

265  if

(segments.size() && segments[0].m_exon ==

false

) {

269  for

(

size_t

k (0); k < segments.size(); ++k) {

270  TSeg

& s (segments[k]);

272  if

(gap_start_idx == -1) {

273

gap_start_idx =

int

(k);

275

s.

m_box

[0] = segments[k-1].m_box[1] + 1;

276

s.

m_box

[2] = segments[k-1].m_box[3] + 1;

281  if

(gap_start_idx >= 0) {

282  TSeg

&

g

= segments[gap_start_idx];

283  g

.m_box[1] = s.

m_box

[0] - 1;

284  g

.m_box[3] = s.

m_box

[2] - 1;

285  g

.m_len =

g

.m_box[1] -

g

.m_box[0] + 1;

286  g

.m_details.resize(0);

287

new_segments.push_back(

g

);

290

new_segments.push_back(s);

294  if

(gap_start_idx >= 0) {

295  TSeg

&

g

(segments[gap_start_idx]);

296  g

.m_box[1] = segments[segments.size()-1].m_box[1];

297  g

.m_box[3] = segments[segments.size()-1].m_box[3];

298  g

.m_len =

g

.m_box[1] -

g

.m_box[0] + 1;

299  g

.m_details.resize(0);

300

new_segments.push_back(

g

);

303

segments.swap(new_segments);

308  if

(

len

== 0)

return

;

312

string::iterator irs, irs0, irs1;

316  if

(irs1 - irs0 <= (

int

)

len

) {

323  for

(irs = irs0; irs != irs1; ++irs) {

351  char

c1 = j1 >= 0?

m_seq

[j1]:

' '

;

354  char

c2 = j2 >= 0?

m_seq

[j2]:

' '

;

361  if

(

len

== 0)

return

;

365

string::reverse_iterator irs, irs0, irs1;

369  if

(irs1 - irs0 <= (

int

)

len

) {

376  for

(irs = irs0; irs != irs1; ++irs) {

402  const size_t

adim = s.

m_annot

.size();

403  if

(adim > 2 && s.

m_annot

[adim - 3] ==

'>'

) {

415  if

(pos == string::npos) {

427  if

(pos == string::npos) {

439  int

score = 0, maxscore = -2;

440

string::reverse_iterator rirs0, rirs1, rirs, rirs_max;

444  for

(rirs = rirs0; rirs != rirs1; ++rirs) {

450  if

(score >= maxscore) {

455  size_t len

= rirs1 - rirs_max - 1;

463  int

score = 0, maxscore = -2;

464

string::iterator irs0, irs1, irs, irs_max;

468  for

(irs = irs0; irs != irs1; ++irs) {

474  if

(score >= maxscore) {

479  size_t len

= irs1 - irs_max - 1;

493  if

(len_total <= 20)

return

;

497

string::iterator irs0 = s.

m_details

.begin(),

500  for

(irs = irs0; irs != irs1; ++irs) {

508  int

minlen =

max

(20, len_total/5);

509  size_t

pos = irs1 - irs0 - minlen;

511  if

( pos == string::npos )

return

;

512

pos = s.

m_details

.find_last_not_of(

'M'

, pos);

513  if

( pos == string::npos )

return

;

514

irs1 = irs0 + pos + 1;

520

string::iterator irs_tr = s.

m_details

.end();

523  for

(irs = irs0; irs != irs1; ++irs) {

529  double

rid = (match_total -

match

) / (

double

)(len_total -

len

);

536

match_total -=

match

;

543  if

(irs_tr == s.

m_details

.end())

return

;

558  if

(len_total <= 20)

return

;

562

string::reverse_iterator irs0 = s.

m_details

.rbegin(),

565  for

(irs = irs0; irs != irs1; ++irs) {

573  size_t

pos =

max

(20, len_total/5) - 1;

575  if

( pos == string::npos )

return

;

576

pos = s.

m_details

.find_first_not_of(

'M'

, pos);

577  if

( pos == string::npos )

return

;

584

string::reverse_iterator irs_tr = s.

m_details

.rend();

587  for

(irs = irs0; irs != irs1; ++irs) {

593  double

lid = (match_total -

match

) / (

double

)(len_total -

len

);

600

match_total -=

match

;

607  if

( irs_tr == s.

m_details

.rend() )

return

;

Seq-loc iterator class – iterates all intervals from a seq-loc in the correct order.

void ImproveFromLeft(TSeg &s)

const double m_MaxPartExonIdentDrop

void Cut50FromLeft(TSeg &s)

void CutToMatchRight(TSeg &s)

void UpdateAnnot(TSeg &s)

static bool HasAbuttingExonOnLeft(TSegs segments, TSeqPos p)

void Cut50FromRight(TSeg &s)

void TrimHolesToCodons(TSegs &segments, objects::CBioseq_Handle &mrna_bio_handle, bool mrna_strand, TSeqPos mrna_len)

void ImproveFromRight(TSeg &s)

CConstRef< CSplicedAligner > m_aligner

bool ThrowAway20_28_90(TSeg &s)

void JoinExons(TSegs &segments, TSeqPos p1, TSeqPos p2)

void AdjustGaps(TSegs &segments)

static bool HasAbuttingExonOnRight(TSegs segments, TSeqPos p)

bool ThrowAwayShortExon(TSeg &s)

void CutFromLeft(size_t len, TSeg &s)

void CutToMatchLeft(TSeg &s)

void CutFromRight(size_t len, TSeg &s)

void Update(const CNWAligner *aligner)

unsigned int TSeqPos

Type for sequence locations and lengths.

#define ITERATE(Type, Var, Cont)

ITERATE macro to sequence through container elements.

#define NCBI_THROW(exception_class, err_code, message)

Generic macro to throw an exception, given the exception class, error code and message string.

TObjectType * GetNonNullPointer(void) const

Get pointer value and throw a null pointer exception if pointer is null.

#define END_NCBI_SCOPE

End previously defined NCBI scope.

#define BEGIN_NCBI_SCOPE

Define ncbi namespace.

TTo GetTo(void) const

Get the To member data.

TFrom GetFrom(void) const

Get the From member data.

unsigned int

A callback function used to compare two keys in a database.

double r(size_t dimension_, const Int4 *score_, const double *prob_, double theta_)

static int match(PCRE2_SPTR start_eptr, PCRE2_SPTR start_ecode, uint16_t top_bracket, PCRE2_SIZE frame_size, pcre2_match_data *match_data, match_block *mb)

const char g_msg_InvalidRange[]

int g(Seg_Gsm *spe, Seq_Mtf *psm, Thd_Gsm *tdg)


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4