Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save nicklangridge/47d688e8272876aa02d48b02d5468af3 to your computer and use it in GitHub Desktop.
Save nicklangridge/47d688e8272876aa02d48b02d5468af3 to your computer and use it in GitHub Desktop.
Fetch polyploid mlss
use strict;
use feature 'say';
use Bio::EnsEMBL::Registry;
my $reg = 'Bio::EnsEMBL::Registry';
$reg->load_registry_from_db(
-host => 'mysql-eg-staging-2',
-user => 'ensro',
-port => '4275',
);
my $genome_db_adaptor = $reg->get_adaptor( "Plants", "compara", "GenomeDB");
my $genome_db = $genome_db_adaptor->fetch_by_registry_name('triticum_aestivum');
say $genome_db->dbID;
my $mlss_adaptor = $reg->get_adaptor("Plants", "compara", "MethodLinkSpeciesSet");
my $mlss = $mlss_adaptor->fetch_by_method_link_type_GenomeDBs('POLYPLOID', [$genome_db], 1);
say $mlss->dbID;
@nicklangridge
Copy link
Author

Output is

2080
Can't call method "dbID" on an undefined value at test.pl line 22.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment