Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Z
zmap
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ensembl-gh-mirror
zmap
Commits
246f6511
Commit
246f6511
authored
15 years ago
by
edgrif
Browse files
Options
Downloads
Patches
Plain Diff
fix colinear markers...again...sigh....
parent
a6742524
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/zmapWindow/zmapWindowColBump.c
+25
-31
25 additions, 31 deletions
src/zmapWindow/zmapWindowColBump.c
with
25 additions
and
31 deletions
src/zmapWindow/zmapWindowColBump.c
+
25
−
31
View file @
246f6511
...
...
@@ -27,9 +27,9 @@
*
* Exported functions: See zmapWindow_P.h
* HISTORY:
* Last edited: Dec 1
1 09:48
2009 (edgrif)
* Last edited: Dec 1
8 11:11
2009 (edgrif)
* Created: Tue Sep 4 10:52:09 2007 (edgrif)
* CVS info: $Id: zmapWindowColBump.c,v 1.5
2
2009-12-1
6
11:
08:36
edgrif Exp $
* CVS info: $Id: zmapWindowColBump.c,v 1.5
3
2009-12-1
8
11:
12:41
edgrif Exp $
*-------------------------------------------------------------------
*/
...
...
@@ -2382,13 +2382,13 @@ static GList *removeNonColinear(GList *first_list_item, ZMapGListDirection direc
/* Function to check whether the homol blocks for two features are colinear.
*
*
features are alignment features and have a match threshold
*
Assumptions:
*
* features are
o
n same
strand
*
* features are
i
n
correct order, i.e. feat_1 is 5' of feat_2
*
*
features have the same style
*
-
features are
i
n
the
same
feature set.
*
- features are alignment features and have a match threshold
*
-
features are
o
n
same strand
*
- features are in correct order, i.e. feat_1 is 5' of feat_2
*
and they do not overlap in their _reference_ coords.
*
* Returns COLINEAR_INVALID if the features overlap or feat_2 is 5' of feat_1,
* otherwise returns COLINEAR_NOT if homols are not colinear,
...
...
@@ -2405,45 +2405,40 @@ static ColinearityType featureHomolIsColinear(ZMapWindow window, unsigned int m
zMapAssert
(
zMapFeatureIsValidFull
((
ZMapFeatureAny
)
feat_1
,
ZMAPFEATURE_STRUCT_FEATURE
))
;
zMapAssert
(
zMapFeatureIsValidFull
((
ZMapFeatureAny
)
feat_2
,
ZMAPFEATURE_STRUCT_FEATURE
))
;
zMapAssert
(
feat_1
->
s
ty
le_id
==
feat_2
->
s
ty
le_id
)
;
zMapAssert
(
feat_1
->
parent
==
feat_2
->
parent
)
;
zMapAssert
(
feat_1
->
ty
pe
==
ZMAPSTYLE_MODE_ALIGNMENT
&&
feat_1
->
type
==
feat_2
->
ty
pe
)
;
zMapAssert
(
feat_1
->
original_id
==
feat_2
->
original_id
)
;
zMapAssert
(
feat_1
->
strand
==
feat_2
->
strand
)
;
zMapAssert
(
feat_1
->
feature
.
homol
.
strand
==
feat_2
->
feature
.
homol
.
strand
)
;
/* Only markers for features that don't overlap on reference sequence. */
if
(
feat_1
->
x2
<
feat_2
->
x1
)
{
int
prev_end
=
0
,
curr_start
=
0
;
ZMapStrand
reference
,
match
;
ZMapFeature
top
,
bottom
;
reference
=
feat_1
->
strand
;
match
=
feat_1
->
feature
.
homol
.
strand
;
/* When match is from reverse strand of homol then homol blocks are in reversed order
* but coords are still _forwards_. Revcomping reverses order of homol blocks
* but as before coords are still forwards. */
if
(
feat_1
->
feature
.
homol
.
strand
==
ZMAPSTRAND_FORWARD
)
if
((
reference
==
ZMAPSTRAND_FORWARD
&&
match
==
ZMAPSTRAND_FORWARD
)
||
(
reference
==
ZMAPSTRAND_REVERSE
&&
match
==
ZMAPSTRAND_REVERSE
))
{
if
(
window
->
revcomped_features
)
prev_end
=
feat_2
->
feature
.
homol
.
y2
;
else
prev_end
=
feat_1
->
feature
.
homol
.
y2
;
if
(
window
->
revcomped_features
)
curr_start
=
feat_1
->
feature
.
homol
.
y1
;
else
curr_start
=
feat_2
->
feature
.
homol
.
y1
;
top
=
feat_1
;
bottom
=
feat_2
;
}
else
{
if
(
window
->
revcomped_features
)
prev_end
=
feat_1
->
feature
.
homol
.
y2
;
else
prev_end
=
feat_2
->
feature
.
homol
.
y2
;
if
(
window
->
revcomped_features
)
curr_start
=
feat_2
->
feature
.
homol
.
y1
;
else
curr_start
=
feat_1
->
feature
.
homol
.
y1
;
top
=
feat_2
;
bottom
=
feat_1
;
}
prev_end
=
top
->
feature
.
homol
.
y2
;
curr_start
=
bottom
->
feature
.
homol
.
y1
;
/* Watch out for arithmetic here, remember that if block coords are one apart
* in the _right_ direction then it's a perfect match. */
diff
=
abs
(
prev_end
-
(
curr_start
-
1
))
;
...
...
@@ -2463,7 +2458,6 @@ static ColinearityType featureHomolIsColinear(ZMapWindow window, unsigned int m
static
void
invoke_bump_to_initial
(
ZMapWindowContainerGroup
container
,
FooCanvasPoints
*
points
,
ZMapContainerLevelType
level
,
gpointer
user_data
)
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment