PyBioMart error only for S. cerevisiae?
0
0
Entering edit mode
2.2 years ago
ngarber ▴ 60

I'm trying to get yeast and human protein sequences, and the human one works, but yeast doesn't - anyone know what's going on? Here is my code:

>>> server = pybiomart.Server(host="http://www.ensembl.org")
>>> mart = server["ENSEMBL_MART_ENSEMBL"]
>>> hsapiens_dataset = mart["hsapiens_gene_ensembl"]
>>> scerevisiae_dataset = mart["scerevisiae_gene_ensembl"]

>>> hsapiens_df = hsapiens_dataset.query(attributes = ["ensembl_peptide_id", "peptide"])
>>> hsapiens_df
                       Peptide                             Protein stable ID
0       MAAAAGMLLLGLLQAGGSVLGQAMEKVTGGNLLSMLLIACAFTLSL...   ENSP00000003100
1       MAALLLGAVLLVAQPQLVPSRPAELGQQELLRKAGTLQDDVRDGVA...   ENSP00000002596
2       MTLLTFRDVAIEFSLEEWKCLDLAQQNLYRDVMLENYRNLFSVGLT...   ENSP00000005082
3       MLLGELGVFASYAFAPLSLIVPLSAVSVIASAIIGIIFIKEKWKPK...   ENSP00000003912
4       MTAELQQDDAAGAADGHGSSCQMLLNQLREITGIQDPSFLHEALKA...   ENSP00000003302
...                                                   ...               ...
120708  MRLDNMLLAEGVAGPEKGGGSAAAAAAAAASGGAGSDNSVEHSDYR...   ENSP00000514644
120709  MGTTASTAQQTVSAGTPFEGLQGSGTMDSRHSVSIHSFQSTSLHNS...   ENSP00000513343
120710  XTVLVHTREAATRNMEKIQVIKDFPWILADEQDVHMHDPRLIPLKT...   ENSP00000513219
120711  MRTEDLPKAVVFLEPQWYRVLEKDSVTLKCQGAYSPEDNSTQWFHN...   ENSP00000514360
120712  MADEKPSNGVLVHMVKLLIKTFLDGIFDDLMENNVLNTDEIHLIGK...   ENSP00000515267

[120713 rows x 2 columns]

>>> scerevisiae_df = scerevisiae_dataset.query(attributes = ["ensembl_peptide_id", "peptide"])
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/tiltwolf/.local/lib/python3.10/site-packages/pybiomart/dataset.py", line 266, in query
    raise BiomartException(response.text)
pybiomart.base.BiomartException: Query ERROR: caught BioMart::Exception::Query: returning undef ... missing attributes for your exportable? 

Update: there appears to be an error on BioMart's end, because I get the same error if I try to query the peptide sequence through the BioMart website. Is it happening for others?

pybiomart python biomart • 388 views
ADD COMMENT

Login before adding your answer.

Traffic: 2614 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6