Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
ensembl
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
1
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
ensembl
Commits
ff5dbe26
Commit
ff5dbe26
authored
12 years ago
by
Web Group
Browse files
Options
Downloads
Patches
Plain Diff
Copy is_patch onto branch 66 now that anacode have moved on. -- ds23
parent
891d5015
Branches
release/67
Tags
cvs/release/ensembl/67
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
modules/Bio/EnsEMBL/Utils/ConversionSupport.pm
+25
-0
25 additions, 0 deletions
modules/Bio/EnsEMBL/Utils/ConversionSupport.pm
with
25 additions
and
0 deletions
modules/Bio/EnsEMBL/Utils/ConversionSupport.pm
+
25
−
0
View file @
ff5dbe26
...
...
@@ -1194,6 +1194,31 @@ sub split_chromosomes_by_size {
return
$chr_slices
;
}
=head2 is_patch
Arg[1] : B::E::Slice
Example : if ($support->is_patch($slice)) { ...
Description : Looks at seq_region attributes to decide if a slice is a patch or not
If PATCH seq_region_attrib is not there check to see if name suggests it is a PATCH
Return type : true/false
=cut
sub
is_patch
{
my
(
$self
,
$slice
)
=
@_
;
my
@patch_attrib_types
=
qw(patch_fix patch_novel)
;
#seq_region_attribs used to define a patch
foreach
my
$attrib_type
(
@patch_attrib_types
)
{
if
(
@
{
$slice
->
get_all_Attributes
(
$attrib_type
)})
{
return
1
;
}
}
if
(
$slice
->
seq_region_name
=~
/PATCH/
)
{
$self
->
log_warning
(
$slice
->
seq_region_name
.
"
has a PATCH name does not have a patch seq_region_attrib, please check if it was present in loutre
\n
");
return
1
;
}
return
0
;
}
=head2 log
Arg[1] : String $txt - the text to log
...
...
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