Package Bio :: Package UniProt :: Module GOA
[hide private]
[frames] | no frames]

Module GOA

source code

Parsers for the GAF, GPA and GPI formats from UniProt-GOA.

Uniprot-GOA README + GAF format description:
ftp://ftp.ebi.ac.uk/pub/databases/GO/goa/UNIPROT/README

GAF formats:
http://www.geneontology.org/GO.format.annotation.shtml
gp_association (GPA format) README:
ftp://ftp.ebi.ac.uk/pub/databases/GO/goa/UNIPROT/gp_association_readme

gp_information (GPI format) README:
ftp://ftp.ebi.ac.uk/pub/databases/GO/goa/UNIPROT/gp_information_readme

Functions [hide private]
 
_gpi10iterator(handle)
Read GPI 1.0 format files (PRIVATE).
source code
 
_gpi11iterator(handle)
Read GPI 1.0 format files (PRIVATE).
source code
 
gpi_iterator(handle)
Read GPI format files.
source code
 
_gpa10iterator(handle)
Read GPA 1.0 format files (PRIVATE).
source code
 
_gpa11iterator(handle)
Read GPA 1.1 format files (PRIVATE).
source code
 
gpa_iterator(handle)
Wrapper function: read GPA format files.
source code
 
_gaf20iterator(handle) source code
 
_gaf10iterator(handle) source code
 
_gaf10byproteiniterator(handle) source code
 
_gaf20byproteiniterator(handle) source code
 
gafbyproteiniterator(handle)
Iterates over records in a gene association file.
source code
 
gafiterator(handle)
Iterate pver a GAF 1.0 or 2.0 file.
source code
 
writerec(outrec, handle, fields=['DB', 'DB_Object_ID', 'DB_Object_Symbol', 'Qualifier', 'GO_ID...)
Write a single UniProt-GOA record to an output stream.
source code
 
writebyproteinrec(outprotrec, handle, fields=['DB', 'DB_Object_ID', 'DB_Object_Symbol', 'Qualifier', 'GO_ID...)
Write a list of GAF records to an output stream.
source code
 
record_has(inrec, fieldvals)
Accepts a record, and a dictionary of field values.
source code
Variables [hide private]
  GAF20FIELDS = ['DB', 'DB_Object_ID', 'DB_Object_Symbol', 'Qual...
  GAF10FIELDS = ['DB', 'DB_Object_ID', 'DB_Object_Symbol', 'Qual...
  GPA10FIELDS = ['DB', 'DB_Object_ID', 'Qualifier', 'GO_ID', 'DB...
  GPA11FIELDS = ['DB', 'DB_Object_ID', 'Qualifier', 'GO_ID', 'DB...
  GPI10FIELDS = ['DB', 'DB_subset', 'DB_Object_ID', 'DB_Object_S...
  GPI11FIELDS = ['DB_Object_ID', 'DB_Object_Symbol', 'DB_Object_...
  __package__ = 'Bio.UniProt'
Function Details [hide private]

_gpi10iterator(handle)

source code 
Read GPI 1.0 format files (PRIVATE).

This iterator is used to read a gp_information.goa_uniprot
file which is in the GPI 1.0 format.

_gpi11iterator(handle)

source code 
Read GPI 1.0 format files (PRIVATE).

This iterator is used to read a gp_information.goa_uniprot
file which is in the GPI 1.0 format.

gpi_iterator(handle)

source code 
Read GPI format files.

This function should be called to read a
gp_information.goa_uniprot file. At the moment, there is
only one format, but this may change, so 
this function is a placeholder a future wrapper.

_gpa10iterator(handle)

source code 
Read GPA 1.0 format files (PRIVATE).

This iterator is used to read a gp_association.*
file which is in the GPA 1.0 format. Do not call directly. Rather,
use the gpaiterator function.

_gpa11iterator(handle)

source code 
Read GPA 1.1 format files (PRIVATE).

This iterator is used to read a gp_association.goa_uniprot
file which is in the GPA 1.1 format. Do not call directly. Rather
use the gpa_iterator function

gpa_iterator(handle)

source code 
Wrapper function: read GPA format files.

This function should be called to read a
gene_association.goa_uniprot file. Reads the first record and
returns a gpa 1.1 or a gpa 1.0 iterator as needed

gafbyproteiniterator(handle)

source code 
Iterates over records in a gene association file. 

Returns a list of all consecutive records with the same DB_Object_ID
This function should be called to read a
gene_association.goa_uniprot file. Reads the first record and
returns a gaf 2.0 or a gaf 1.0 iterator as needed

gafiterator(handle)

source code 
Iterate pver a GAF 1.0 or 2.0 file.

This function should be called to read a
gene_association.goa_uniprot file. Reads the first record and
returns a gaf 2.0 or a gaf 1.0 iterator as needed

writerec(outrec, handle, fields=['DB', 'DB_Object_ID', 'DB_Object_Symbol', 'Qualifier', 'GO_ID...)

source code 
Write a single UniProt-GOA record to an output stream. 

Caller should know the  format version. Default: gaf-2.0
If header has a value, then it is assumed this is the first record,
a header is written.

writebyproteinrec(outprotrec, handle, fields=['DB', 'DB_Object_ID', 'DB_Object_Symbol', 'Qualifier', 'GO_ID...)

source code 
Write a list of GAF records to an output stream. 

Caller should know the  format version. Default: gaf-2.0
If header has a value, then it is assumed this is the first record,
a header is written. Typically the list is the one read by fafbyproteinrec, which
contains all consecutive lines with the same DB_Object_ID

record_has(inrec, fieldvals)

source code 
Accepts a record, and a dictionary of field values. 

The format is {'field_name': set([val1, val2])}.
If any field in the record has  a matching value, the function returns
True. Otherwise, returns False.


Variables Details [hide private]

GAF20FIELDS

Value:
['DB',
 'DB_Object_ID',
 'DB_Object_Symbol',
 'Qualifier',
 'GO_ID',
 'DB:Reference',
 'Evidence',
 'With',
...

GAF10FIELDS

Value:
['DB',
 'DB_Object_ID',
 'DB_Object_Symbol',
 'Qualifier',
 'GO_ID',
 'DB:Reference',
 'Evidence',
 'With',
...

GPA10FIELDS

Value:
['DB',
 'DB_Object_ID',
 'Qualifier',
 'GO_ID',
 'DB:Reference',
 'Evidence code',
 'With',
 'Interacting_taxon_ID',
...

GPA11FIELDS

Value:
['DB',
 'DB_Object_ID',
 'Qualifier',
 'GO_ID',
 'DB:Reference',
 'ECO_Evidence_code',
 'With',
 'Interacting_taxon_ID',
...

GPI10FIELDS

Value:
['DB',
 'DB_subset',
 'DB_Object_ID',
 'DB_Object_Symbol',
 'DB_Object_Name',
 'DB_Object_Synonym',
 'DB_Object_Type',
 'Taxon',
...

GPI11FIELDS

Value:
['DB_Object_ID',
 'DB_Object_Symbol',
 'DB_Object_Name',
 'DB_Object_Synonym',
 'DB_Object_Type',
 'Taxon',
 'Parent_Object_ID',
 'DB_Xref',
...