Package Bio :: Package expressions :: Package swissprot :: Module sprot38
[hide private]
[frames] | no frames]

Module sprot38

source code

Parser for the SWISS-PROT 38 format.

You probably want to use the variables 'record' (for a single record) and 'format' (for a set of records).

Functions [hide private]
 
Simple(tag, tag_data) source code
Variables [hide private]
  ID = Martel.Group("ID", Martel.Str("ID ")+ Std.dbid(Martel.W...
  AC = Martel.Group("AC", Martel.Str("AC ")+ Std.dbid(Martel.W...
  AC_block = Martel.Group("AC_block", Martel.Rep1(AC))
  DT_created = Martel.Group("DT_created", Martel.Str("DT ")+ T...
  DT_seq_update = Martel.Group("DT_seq_update", Martel.Re(r"DT ...
  DT_ann_update = Martel.Group("DT_ann_update", Martel.Re(r"DT ...
  DE = Martel.Group("DE", Martel.Str("DE ")+ Std.description(M...
  DE_block = Std.description_block(Martel.Group("DE_block", Mart...
  GN = Simple("GN", "gene_names")
  GN_block = Martel.Group("GN_block", Martel.Rep1(GN))
  OS = Simple("OS", "organism_species")
  OS_block = sprot38.OS_block
  OG = Simple("OG", "organelle")
  OG_block = sprot38.OG_block
  OC = Simple("OC", "organism_classification")
  OC_block = sprot38.OC_block
  RN = sprot38.RN
  RP = sprot38.RP
  RC = Simple("RC", "reference_comment")
  RC_block = sprot38.RC_block
  RX = sprot38.RX
  RA = Simple("RA", "reference_author")
  RA_block = sprot38.RA_block
  RT = Simple("RT", "reference_title")
  RT_block = sprot38.RT_block
  RL = Simple("RL", "reference_location")
  RL_block = sprot38.RL_block
  reference = Martel.Group("reference", RN+ RP+ Martel.Opt(RC_bl...
  CC_begin = Martel.Group("CC", Martel.Re("CC -!- ")+ Martel.T...
  CC = Martel.Group("CC", Martel.Re("CC ")+ Martel.ToEol("...
  single_comment = Martel.Group("comment", CC_begin+ Martel.Rep(...
  CC_copyright_begin = Martel.Group("CC_copyright_begin", Martel...
  CC_copyright = Martel.Group("CC_copyright", Martel.Re("CC (?...
  CC_copyright_end = Martel.Group("CC_copyright_end", Martel.Re(...
  bogus_DR_group = Martel.Group("bogus_DR_block", Martel.Re(r"(?...
  comment = Martel.Group("comment_block", Martel.Rep(single_comm...
  _to_secondary_end = Martel.Re(r"([^.\R]|(?!.\R)\.)+")
  database_id = Std.dbxref_dbname(Martel.UntilSep("database_iden...
  primary_id = Std.dbxref_dbid(Martel.UntilSep("primary_identifi...
  secondary_id = Std.dbxref_dbid(Martel.Group("secondary_identif...
  real_DR_general = Std.dbxref(database_id+ Martel.Str("; ")+ pr...
  fast_DR_general = Std.fast_dbxref(real_DR_general, {"style": "...
  DR_general = Martel.FastFeature(fast_DR_general, "fast-sp-dbxr...
  real_DR_prosite = Std.dbxref(Std.dbxref_dbname(Martel.Group("d...
  fast_DR_prosite = Std.fast_dbxref(real_DR_prosite, {"style": "...
  DR_prosite = Martel.FastFeature(fast_DR_prosite, "fast-sp-dbxr...
  real_DR_embl = Std.dbxref(Std.dbxref_dbname(Martel.Group("data...
  fast_DR_embl = Std.fast_dbxref(real_DR_embl, {"style": "sp-emb...
  DR_embl = Martel.FastFeature(fast_DR_embl, "fast-sp-dbxref", r...
  DR = Martel.Group("DR", Martel.Str("DR ")+ Martel.Group("dat...
  DR_block = sprot38.DR_block
  KW = Simple("KW", "keyword")
  KW_block = Martel.Group("KW_block", Martel.Rep1(KW))
  FT_name = Std.feature_name(Martel.Re(r".{8}"))
  FT_start = Std.feature_location_start(Martel.Re(r".{6}"))
  FT_end = Std.feature_location_end(Martel.Re(r".{6}"))
  FT_desc = Std.feature_description(Martel.UntilEol())
  FT_range = Martel.Str("FT ")+ FT_name+ Martel.Str(" ")+ FT_s...
  FT_continuation = Martel.Str("FT ...
  FT = Std.feature(FT_range+ Martel.Rep(FT_continuation), {"loca...
  feature_block = Std.feature_block(Martel.Rep1(FT), {"style": "...
  SQ = Martel.Group("SQ", Martel.Re("SQ SEQUENCE +(?P<sequence...
  SQ_data = Martel.Str(" ")+ Std.sequence(Martel.UntilEol())...
  sequence = Std.sequence_block(SQ+ Martel.Rep(SQ_data), {"alpha...
  end = Martel.Group("END", Martel.Str("//")+ Martel.AnyEol())
  record = Std.record(ID+ AC_block+ DT_created+ DT_seq_update+ D...
  format_expression = Martel.Group("dataset", Martel.Rep1(record...
  format = Martel.ParseRecords("dataset", {"format": "swissprot/...
  __warningregistry__ = {('Bio.expressions was deprecated, as it...
Variables Details [hide private]

ID

Value:
Martel.Group("ID", Martel.Str("ID   ")+ Std.dbid(Martel.Word("entry_na\
me"), {"type": "primary", "dbname": "sp"})+ Martel.Spaces()+ Martel.Wo\
rd("data_class_table")+ Martel.Str(";")+ Martel.Spaces()+ Martel.Word(\
"molecule_type")+ Martel.Str(";")+ Martel.Spaces()+ Martel.Digits("seq\
uence_length")+ Martel.Str(" AA.")+ Martel.AnyEol())

AC

Value:
Martel.Group("AC", Martel.Str("AC   ")+ Std.dbid(Martel.Word("ac_numbe\
r"), {"type": "accession", "dbname": "sp"})+ Martel.Str(";")+ Martel.R\
ep(Martel.Str(" ")+ Std.dbid(Martel.Word("ac_number"), {"type": "acces\
sion"})+ Martel.Str(";"))+ Martel.AnyEol())

DT_created

Value:
Martel.Group("DT_created", Martel.Str("DT   ")+ Time.make_expression("\
%(DD)-%(Jan)-%(YYYY)")+ Martel.Re(" \(Rel. (?P<release>\d\d), Created\\
)\R"))

DT_seq_update

Value:
Martel.Group("DT_seq_update", Martel.Re(r"DT   (?P<day>\d\d)-(?P<month\
>...)-(?P<year>\d{4}) \(Rel. " r"(?P<release>\d\d), Last sequence upda\
te\)\R"))

DT_ann_update

Value:
Martel.Group("DT_ann_update", Martel.Re(r"DT   (?P<day>\d\d)-(?P<month\
>...)-(?P<year>\d{4}) \(Rel. " r"(?P<release>\d\d), Last annotation up\
date\)\R"))

DE

Value:
Martel.Group("DE", Martel.Str("DE   ")+ Std.description(Martel.UntilEo\
l("description"))+ Martel.AnyEol())

DE_block

Value:
Std.description_block(Martel.Group("DE_block", Martel.Rep1(DE)))

reference

Value:
Martel.Group("reference", RN+ RP+ Martel.Opt(RC_block)+ Martel.Opt(RX)\
+ RA_block+ Martel.Opt(RT_block)+ RL_block)

CC_begin

Value:
Martel.Group("CC", Martel.Re("CC   -!- ")+ Martel.ToEol("comment_text"\
))

CC

Value:
Martel.Group("CC", Martel.Re("CC       ")+ Martel.ToEol("comment_text"\
))

single_comment

Value:
Martel.Group("comment", CC_begin+ Martel.Rep(CC))

CC_copyright_begin

Value:
Martel.Group("CC_copyright_begin", Martel.Re("CC   -+\R"))

CC_copyright

Value:
Martel.Group("CC_copyright", Martel.Re("CC   (?!-+\R)")+ Martel.ToEol(\
"copyright"))

CC_copyright_end

Value:
Martel.Group("CC_copyright_end", Martel.Re("CC   -+\R"))

bogus_DR_group

Value:
Martel.Group("bogus_DR_block", Martel.Re(r"(?P<DR>DR   (?P<database_id\
entifier>MIM); " r"(?P<primary_identifier>601385); " r"(?P<secondary_i\
dentifier>-).\R)"))

comment

Value:
Martel.Group("comment_block", Martel.Rep(single_comment)+ Martel.Opt(b\
ogus_DR_group)+ Martel.Opt(CC_copyright_begin+ Martel.Rep(CC_copyright\
)+ CC_copyright_end))

database_id

Value:
Std.dbxref_dbname(Martel.UntilSep("database_identifier", ";"), {"style\
": "sp"})

primary_id

Value:
Std.dbxref_dbid(Martel.UntilSep("primary_identifier", ";"), {"type": "\
primary"})

secondary_id

Value:
Std.dbxref_dbid(Martel.Group("secondary_identifier", _to_secondary_end\
), {"type": "accession"})

real_DR_general

Value:
Std.dbxref(database_id+ Martel.Str("; ")+ primary_id+ Martel.Str("; ")\
+ secondary_id,)

fast_DR_general

Value:
Std.fast_dbxref(real_DR_general, {"style": "sp-general"})

DR_general

Value:
Martel.FastFeature(fast_DR_general, "fast-sp-dbxref", real_DR_general.\
group_names())

real_DR_prosite

Value:
Std.dbxref(Std.dbxref_dbname(Martel.Group("database_identifier", Marte\
l.Str("PROSITE", "PFAM")), {"style": "sp"})+ Martel.Str("; ")+ primary\
_id+ Martel.Str("; ")+ Std.dbxref_dbid(Martel.UntilSep(sep= ";"), {"ty\
pe": "accession"})+ Martel.Str("; ")+ Martel.UntilSep("status_identifi\
er", "."),)

fast_DR_prosite

Value:
Std.fast_dbxref(real_DR_prosite, {"style": "sp-prosite"})

DR_prosite

Value:
Martel.FastFeature(fast_DR_prosite, "fast-sp-dbxref", real_DR_prosite.\
group_names())

real_DR_embl

Value:
Std.dbxref(Std.dbxref_dbname(Martel.Group("database_identifier", Marte\
l.Str("EMBL")), {"style": "sp"})+ Martel.Str("; ")+ primary_id+ Martel\
.Str("; ")+ Std.dbxref_dbid(Martel.UntilSep("secondary_identifier", ";\
"), {"type": "accession"})+ Martel.Str("; ")+ Martel.UntilSep("status_\
identifier", "."),)

fast_DR_embl

Value:
Std.fast_dbxref(real_DR_embl, {"style": "sp-embl"})

DR_embl

Value:
Martel.FastFeature(fast_DR_embl, "fast-sp-dbxref", real_DR_embl.group_\
names())

DR

Value:
Martel.Group("DR", Martel.Str("DR   ")+ Martel.Group("database_referen\
ce", DR_embl | DR_prosite | DR_general)+ Martel.Str(".")+ Martel.AnyEo\
l())

FT_range

Value:
Martel.Str("FT   ")+ FT_name+ Martel.Str(" ")+ FT_start+ Martel.Str(" \
")+ FT_end+ Martel.Opt(Martel.Str("       ")+ FT_desc)+ Martel.AnyEol(\
)

FT_continuation

Value:
Martel.Str("FT                                ")+ FT_desc+ Martel.AnyE\
ol()

FT

Value:
Std.feature(FT_range+ Martel.Rep(FT_continuation), {"location-style": \
"sp"})

feature_block

Value:
Std.feature_block(Martel.Rep1(FT), {"style": "swissprot"})

SQ

Value:
Martel.Group("SQ", Martel.Re("SQ   SEQUENCE +(?P<sequence_length>\d+) \
AA;" " +(?P<molecular_weight>\d+) MW;" " +(?P<crc?type=32>\w+) CRC32;\\
R"))

SQ_data

Value:
Martel.Str("     ")+ Std.sequence(Martel.UntilEol())+ Martel.AnyEol()

sequence

Value:
Std.sequence_block(SQ+ Martel.Rep(SQ_data), {"alphabet": "iupac-ambigu\
ous-protein"})

record

Value:
Std.record(ID+ AC_block+ DT_created+ DT_seq_update+ DT_ann_update+ Mar\
tel.Opt(DE_block)+ Martel.Opt(GN_block)+ Martel.Opt(OS_block)+ Martel.\
Opt(OG_block)+ Martel.Opt(OC_block)+ Martel.Group("OX_block", Martel.N\
ullOp())+ Martel.Group("reference_block", Martel.Rep(reference))+ comm\
ent+ Martel.Opt(DR_block)+ Martel.Opt(KW_block)+ Martel.Opt(feature_bl\
ock)+ sequence+ end, {"format": "swissprot/38"})

format_expression

Value:
Martel.Group("dataset", Martel.Rep1(record), {"format": "swissprot/38"\
})

format

Value:
Martel.ParseRecords("dataset", {"format": "swissprot/38"}, record, Rec\
ordReader.EndsWith, ("//\n",))

__warningregistry__

Value:
{('Bio.expressions was deprecated, as it does not work with recent ver\
sions of mxTextTools. If you want to continue to use this module, plea\
se get in contact with the Biopython developers at biopython-dev@biopy\
thon.org to avoid permanent removal of this module from Biopython',
  <type 'exceptions.DeprecationWarning'>,
  9): 1}