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
e9e81a32
Commit
e9e81a32
authored
17 years ago
by
Glenn Proctor
Browse files
Options
Downloads
Patches
Plain Diff
Add ignore_release flag to DBEntryAdaptor store calls.
parent
6dfbffb3
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
misc-scripts/xref_projection/project_display_xrefs.pl
+11
-7
11 additions, 7 deletions
misc-scripts/xref_projection/project_display_xrefs.pl
with
11 additions
and
7 deletions
misc-scripts/xref_projection/project_display_xrefs.pl
+
11
−
7
View file @
e9e81a32
...
...
@@ -12,7 +12,7 @@ use Bio::EnsEMBL::Utils::Eprof qw(eprof_start eprof_end eprof_dump);
my
$method_link_type
=
"
ENSEMBL_ORTHOLOGUES
";
my
(
$conf
,
$compara
,
$from_species
,
@to_multi
,
$print
,
$names
,
$go_terms
,
$delete_names
,
$delete_go_terms
,
$no_backup
,
$full_stats
,
$descriptions
,
$release
,
$no_database
,
$quiet
,
$single_source
,
$max_genes
,
$one_to_many
);
my
(
$conf
,
$compara
,
$from_species
,
@to_multi
,
$print
,
$names
,
$go_terms
,
$delete_names
,
$delete_go_terms
,
$no_backup
,
$full_stats
,
$descriptions
,
$release
,
$no_database
,
$quiet
,
$single_source
,
$max_genes
,
$one_to_many
,
$go_check
);
GetOptions
('
conf=s
'
=>
\
$conf
,
'
compara=s
'
=>
\
$compara
,
...
...
@@ -33,6 +33,7 @@ GetOptions('conf=s' => \$conf,
'
single_source=s
'
=>
\
$single_source
,
'
max_genes=i
'
=>
\
$max_genes
,
'
one_to_many
'
=>
\
$one_to_many
,
'
go_check
'
=>
\
$go_check
,
'
help
'
=>
sub
{
usage
();
exit
(
0
);
});
$|
=
1
;
# auto flush stdout
...
...
@@ -255,19 +256,19 @@ sub project_display_names {
if
(
$type
eq
"
Gene
")
{
$to_gene
->
add_DBEntry
(
$dbEntry
);
$to_dbea
->
store
(
$dbEntry
,
$to_gene
->
dbID
(),
'
Gene
')
if
(
!
$print
);
$to_dbea
->
store
(
$dbEntry
,
$to_gene
->
dbID
(),
'
Gene
'
,
1
)
if
(
!
$print
);
}
elsif
(
$type
eq
"
Transcript
"
||
!
$type
)
{
$to_transcript
->
add_DBEntry
(
$dbEntry
);
$to_dbea
->
store
(
$dbEntry
,
$to_transcript
->
dbID
(),
'
Transcript
')
if
(
!
$print
);
$to_dbea
->
store
(
$dbEntry
,
$to_transcript
->
dbID
(),
'
Transcript
'
,
1
)
if
(
!
$print
);
}
elsif
(
$type
eq
"
Translation
")
{
my
$to_translation
=
$to_transcript
->
translation
();
return
if
(
!
$to_translation
);
$to_translation
->
add_DBEntry
(
$dbEntry
);
$to_dbea
->
store
(
$dbEntry
,
$to_translation
->
dbID
(),
'
Translation
')
if
(
!
$print
);
$to_dbea
->
store
(
$dbEntry
,
$to_translation
->
dbID
(),
'
Translation
'
,
1
)
if
(
!
$print
);
}
else
{
...
...
@@ -311,7 +312,7 @@ sub project_go_terms {
my
$from_latin_species
=
ucfirst
(
Bio::EnsEMBL::
Registry
->
get_alias
(
$from_species
));
my
$to_go_xrefs
=
$to_translation
->
get_all_DBEntries
("
GO
");
my
$to_go_xrefs
=
$to_translation
->
get_all_DBEntries
("
GO
")
if
(
$go_check
)
;
DBENTRY:
foreach
my
$dbEntry
(
@
{
$from_translation
->
get_all_DBEntries
("
GO
")})
{
...
...
@@ -323,7 +324,7 @@ sub project_go_terms {
}
# check that each from GO term isn't already projected
next
if
go_xref_exists
(
$dbEntry
,
$to_go_xrefs
);
next
if
(
$go_check
&&
go_xref_exists
(
$dbEntry
,
$to_go_xrefs
)
)
;
# record statistics by evidence type
foreach
my
$et
(
@
{
$dbEntry
->
get_all_linkage_types
}){
...
...
@@ -342,7 +343,7 @@ sub project_go_terms {
print
$to_translation
->
stable_id
()
.
"
-->
"
.
$dbEntry
->
display_id
()
.
"
\n
"
if
(
$print
);
$to_dbea
->
store
(
$dbEntry
,
$to_translation
->
dbID
(),
'
Translation
')
if
(
!
$print
);
$to_dbea
->
store
(
$dbEntry
,
$to_translation
->
dbID
(),
'
Translation
'
,
1
)
if
(
!
$print
);
}
...
...
@@ -744,6 +745,9 @@ sub usage {
target are named "1 of 3", etc. Currently only affects
display xrefs, not GO terms.
[--go_check] Check if GO term is already assigned, and don
'
t
project
if
it
is
.
Off
by
default
.
[
--
help
]
This
text
.
e
.
g
...
...
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