Module Expr Str Import alias identifier Import alias Import alias Import alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias alias alias alias alias Expr Str Assign NameStore Str Assign NameStore Str Assign NameStore Str Assign NameStore Str Assign NameStore Str Assign NameStore Str Assign NameStore Str Assign NameStore Dict Str Str Str Str Assign NameStore Dict Str Str Str Str Assign NameStore Str Assign TupleStore NameStore NameStore TupleLoad Num Num Assign NameStore Call NameLoad FunctionDef arguments args defaults body Assign NameStore TupleLoad TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str Assign NameStore Call NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Call NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Str keyword Num keyword Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad If CompareNotEq Call NameLoad NameLoad Num body Expr Call AttributeLoad NameLoad attr UnaryOpNot Call AttributeLoad NameLoad attr Assign TupleStore NameStore NameLoad Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call NameLoad NameLoad For NameStore NameLoad body If CompareEq SubscriptLoad NameLoad Index Num Str body Continue Assign NameStore IfExp CompareIn Str NameLoad Str NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr attr NameLoad Num Assign TupleStore NameStore NameStore SubscriptLoad NameLoad Slice Num Assign NameStore Call NameLoad NameLoad Assign NameStore SubscriptLoad NameLoad Index Num Assign NameStore Call AttributeLoad NameLoad attr Str Str If CompareEq Call NameLoad NameLoad Num body Assign NameStore Call AttributeLoad Str attr Num NameLoad orelse Assert CompareEq Call NameLoad NameLoad Num Assign NameStore SubscriptLoad NameLoad Index Num For NameStore Call AttributeLoad NameLoad attr Str body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr Str Assign TupleStore NameStore NameStore TupleLoad Call NameLoad NameLoad Call NameLoad NameLoad Assert CompareLtE NameLoad NameLoad Assign NameStore BinOpSub NameLoad Num Assign NameStore BinOpSub NameLoad NameLoad If CompareLt NameLoad NameLoad body Assign NameStore Num If CompareLt NameLoad NameLoad body Assign NameStore NameLoad Print Call AttributeLoad Str attr GeneratorExp Call NameLoad NameLoad comprehension NameStore TupleLoad NameLoad BinOpSub NameLoad Num NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str ImportFrom alias Assign NameStore Call NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad If CompareLt Call NameLoad NameLoad Num body Expr Call AttributeLoad NameLoad attr UnaryOpNot Call AttributeLoad NameLoad attr Assign NameStore Call NameLoad AttributeLoad NameLoad attr Str For NameStore NameLoad body Assign NameStore Call NameLoad NameLoad Assign NameStore NameLoad Assign NameStore NameLoad Assign TupleStore NameStore NameStore TupleLoad NameLoad NameLoad For NameStore NameLoad body If CompareEq Call AttributeLoad NameLoad attr Str body Continue Assign NameStore SubscriptLoad Call AttributeLoad NameLoad attr Index Num If CompareEq NameLoad Str body Assign NameStore NameLoad If BoolOpAnd NameLoad CompareEq NameLoad Str body If CompareIs NameLoad NameLoad body Assign NameStore SubscriptLoad Call AttributeLoad NameLoad attr Str Index Num Assign NameStore NameLoad If CompareEq NameLoad Str body Assign NameStore NameLoad If BoolOpAnd NameLoad CompareEq NameLoad Str body If CompareIs NameLoad NameLoad body Assign NameStore SubscriptLoad Call AttributeLoad NameLoad attr Str Index Num Assign NameStore NameLoad Assert BoolOpAnd NameLoad NameLoad Print NameLoad Call AttributeLoad Str attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore Call AttributeLoad Str attr NameLoad NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad Call NameLoad NameLoad attr attr Assert UnaryOpNot NameLoad Call AttributeLoad Str attr NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad NameLoad Expr Call NameLoad NameLoad keyword NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str ImportFrom alias Assign NameStore Call NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Str keyword Str keyword Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad If CompareNotEq Call NameLoad NameLoad Num body Expr Call AttributeLoad NameLoad attr UnaryOpNot Call AttributeLoad NameLoad attr Assign TupleStore NameStore NameStore NameStore NameLoad Assign NameStore AttributeLoad NameLoad attr Assign NameStore Str Assign NameStore Str Expr Call NameLoad NameLoad Expr Call NameLoad NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad NameLoad Expr Call NameLoad NameLoad keyword Str keyword Str Assign NameStore Str AugAssignAdd NameStore Str AugAssignAdd NameStore Str AugAssignAdd NameStore Str AugAssignAdd NameStore Str Assign NameStore Num For NameStore Call NameLoad NameLoad body Assign TupleStore NameStore NameStore SubscriptLoad Call AttributeLoad NameLoad attr Slice Num Assign NameStore Call AttributeLoad NameLoad attr NameLoad BinOpAdd NameLoad Str Assign NameStore Call AttributeLoad Str attr NameLoad Assign TupleStore NameStore NameStore Call NameLoad ListLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore NameStore NameLoad Assign NameStore Call NameLoad NameLoad Assert CompareIn NameLoad TupleLoad Num Num Num Assign NameStore Call AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad keyword NameLoad keyword NameLoad keyword NameLoad keyword NameLoad Expr Call NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad AugAssignAdd NameStore Num Print AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str ImportFrom alias alias ImportFrom alias ImportFrom alias Assign NameStore Call NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Str keyword NameLoad keyword Str Expr Call AttributeLoad NameLoad attr Str keyword Str keyword Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad If CompareNotEq Call NameLoad NameLoad Num body Expr Call AttributeLoad NameLoad attr UnaryOpNot Call AttributeLoad NameLoad attr Assign TupleStore NameStore NameStore NameLoad Assign NameStore SubscriptLoad Call AttributeLoad NameLoad attr Str Num Index Num Assign NameStore BinOpAdd NameLoad Str Assign NameStore BinOpAdd NameLoad Str Assign NameStore BinOpAdd NameLoad Str Expr Call NameLoad ListLoad NameLoad Call AttributeLoad Str attr NameLoad Assign NameStore Str Expr Call NameLoad NameLoad Expr Call NameLoad ListLoad NameLoad Str Call AttributeLoad Str attr NameLoad Expr Call NameLoad BinOpAdd Call NameLoad Call AttributeLoad Str attr NameLoad ListLoad Call AttributeLoad Str attr NameLoad If CompareIs AttributeLoad NameLoad attr NameLoad body Assign NameStore Str Expr Call NameLoad NameLoad Expr Call NameLoad ListLoad NameLoad Str Call AttributeLoad Str attr NameLoad Expr Call NameLoad BinOpAdd Call NameLoad Call AttributeLoad Str attr NameLoad ListLoad Call AttributeLoad Str attr NameLoad orelse Assign NameStore AttributeLoad NameLoad attr Assert BoolOpAnd Call AttributeLoad NameLoad attr NameLoad Call AttributeLoad NameLoad attr NameLoad Assign NameStore BinOpAdd NameLoad Str Assign NameStore Call NameLoad NameLoad Str Assign NameStore AttributeLoad NameLoad attr Assign NameStore Str Assign NameStore Str Expr Call NameLoad NameLoad Expr Call NameLoad NameLoad ImportFrom alias Assign NameStore Call NameLoad NameLoad Assert CompareEq Call NameLoad Call NameLoad Call AttributeLoad NameLoad attr Call NameLoad Call NameLoad Call AttributeLoad NameLoad attr Assign NameStore Call NameLoad NameLoad Assign NameStore ListComp Call NameLoad NameLoad comprehension NameStore Call AttributeLoad NameLoad attr Expr Call NameLoad NameLoad Num Num Num keyword Str Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr Call NameLoad NameLoad Assert CompareEq Call NameLoad NameLoad Call NameLoad NameLoad Assign NameStore ListLoad Assign NameStore Call AttributeLoad Str attr NameLoad NameLoad Expr Call NameLoad NameLoad keyword Str keyword Str Assign NameStore Str AugAssignAdd NameStore Str AugAssignAdd NameStore Str AugAssignAdd NameStore Str AugAssignAdd NameStore Str Assign NameStore Str Assign NameStore Num For NameStore Call NameLoad NameLoad body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr attr Str Assign TupleStore NameStore NameStore NameStore TupleLoad SubscriptLoad NameLoad Index Num SubscriptLoad NameLoad Index Num SubscriptLoad NameLoad Index Num Assign NameStore Call AttributeLoad NameLoad attr NameLoad BinOpAdd NameLoad Str Assign NameStore SubscriptLoad Call AttributeLoad NameLoad attr Str Num Index Num Assign NameStore SubscriptLoad NameLoad Index NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad Assign TupleStore NameStore NameStore Call NameLoad ListLoad NameLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call NameLoad NameLoad Assert CompareIn NameLoad TupleLoad Num Num Num Assign NameStore NameLoad If BoolOpAnd CompareEq NameLoad Num CompareNotEq NameLoad Num body Assign NameStore Num If BoolOpAnd CompareNotEq NameLoad Num CompareEq NameLoad Num body Assign NameStore Num Print NameLoad Call AttributeLoad Str attr NameLoad NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr keyword NameLoad If CompareIn Str NameLoad body AugAssignAdd NameStore Str Assign NameStore Call AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad keyword NameLoad keyword NameLoad keyword NameLoad keyword NameLoad keyword NameLoad Expr Call NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad AugAssignAdd NameStore Num Expr Call NameLoad NameLoad Num Num Num keyword Str Print AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad NameLoad body Assign TupleStore NameStore NameStore TupleLoad SubscriptLoad AttributeLoad NameLoad attr Slice NameLoad Call NameLoad Num BinOpAdd NameLoad Num Return TupleLoad NameLoad NameLoad decorator_list NameLoad FunctionDef arguments args NameParam NameParam defaults NameLoad NameLoad body Assign TupleStore NameStore NameStore Call NameLoad NameLoad NameLoad Assign NameStore ListComp BinOpMult ListLoad Str NameLoad comprehension NameStore Call NameLoad NameLoad Assign NameStore Num For NameStore Call NameLoad Num NameLoad Num body For NameStore Call NameLoad Num NameLoad Num body AugAssignAdd NameStore Num Assign NameStore Call AttributeLoad Str attr NameLoad Assign SubscriptStore SubscriptLoad NameLoad Index NameLoad Index NameLoad BinOpAdd NameLoad Str Assign SubscriptStore SubscriptLoad NameLoad Index NameLoad Index BinOpAdd NameLoad Num BinOpAdd NameLoad Str Assign SubscriptStore SubscriptLoad NameLoad Index BinOpAdd NameLoad Num Index NameLoad BinOpAdd NameLoad Str Assign SubscriptStore SubscriptLoad NameLoad Index BinOpAdd NameLoad Num Index BinOpAdd NameLoad Num BinOpAdd NameLoad Str Assign NameStore Dict For NameStore Call NameLoad NameLoad body For NameStore Call NameLoad NameLoad body Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index NameLoad Index NameLoad Assign SubscriptStore NameLoad Index NameLoad Call AttributeLoad Str attr SubscriptLoad NameLoad Index NameLoad BinOpAdd NameLoad Num Return TupleLoad NameLoad NameLoad decorator_list NameLoad FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body Expr Str Assign TupleStore NameStore NameStore Call NameLoad Assign TupleStore NameStore NameStore Call NameLoad Assign NameStore BinOpAdd BinOpDiv BinOpMult Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num NameLoad Num Call NameLoad SubscriptLoad NameLoad Slice Num Assign NameStore Call AttributeLoad Str attr NameLoad SubscriptLoad Str Index BinOpSub NameLoad Num Return SubscriptLoad NameLoad Index NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call NameLoad AttributeLoad NameLoad attr Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Assign TupleStore NameStore NameStore Call NameLoad Assign NameStore AttributeLoad NameLoad attr For NameStore NameLoad body For TupleStore NameStore NameStore Call NameLoad NameLoad body If CompareNotEq NameLoad Num body Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Str decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call AttributeLoad Call AttributeLoad Str attr SubscriptLoad Call AttributeLoad NameLoad attr Slice Num attr Str Str Assign NameStore Call NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call NameLoad AttributeLoad NameLoad attr Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad If CompareNotEq Call NameLoad NameLoad Num body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Assign TupleStore NameStore NameStore NameLoad Assign NameStore Call NameLoad NameLoad Assign NameStore Call NameLoad NameLoad Assign NameStore Call NameLoad NameLoad Assign NameStore Call NameLoad Str Str Print NameLoad Call AttributeLoad NameLoad attr NameLoad Print NameLoad Call AttributeLoad NameLoad attr NameLoad Print NameLoad Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr AttributeLoad NameLoad attr Assign NameStore Call NameLoad Str Str Assign NameStore Call NameLoad Str Str For NameStore Call AttributeLoad NameLoad attr NameLoad Str body Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call NameLoad NameLoad Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Str Index Num Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Str Index Num Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Str Index Num Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Str Index Num Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Str Index Num Assign NameStore NameLoad Assign NameStore Call NameLoad NameLoad Assign NameStore NameLoad Assert CompareEq Call NameLoad NameLoad NameLoad NameLoad Assign NameStore NameLoad Assert CompareIn NameLoad NameLoad Call AttributeLoad Str attr NameLoad NameLoad Assign NameStore SubscriptLoad NameLoad Index NameLoad Assign NameStore SubscriptLoad NameLoad Index NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad NameLoad AugAssignAdd SubscriptStore NameLoad Index NameLoad Num If CompareGt SubscriptLoad NameLoad Index NameLoad Num body Assign NameStore Call AttributeLoad Str attr NameLoad SubscriptLoad NameLoad Index NameLoad AugAssignAdd SubscriptStore NameLoad Index NameLoad Num Expr Call AttributeLoad SubscriptLoad NameLoad Index NameLoad attr NameLoad Assign NameStore Call NameLoad NameLoad For NameStore Call AttributeLoad NameLoad attr NameLoad Str body Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call NameLoad NameLoad Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Str Index Num Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Str Index Num Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Str Index Num Assign NameStore NameLoad Assign NameStore NameLoad Assign NameStore SubscriptLoad NameLoad Index NameLoad Assign NameStore SubscriptLoad NameLoad Index NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad NameLoad AugAssignAdd SubscriptStore NameLoad Index NameLoad Num If CompareGt SubscriptLoad NameLoad Index NameLoad Num body Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad SubscriptLoad NameLoad Index NameLoad Assign NameStore BinOpSub SubscriptLoad NameLoad Index NameLoad Call NameLoad ListLoad NameLoad Assign NameStore Call AttributeLoad Str attr Call NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Call NameLoad Print NameLoad Call AttributeLoad NameLoad attr NameLoad Print NameLoad Call AttributeLoad Str attr NameLoad NameLoad Print NameLoad BinOpMult Str Num Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr Call NameLoad NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr decorator_list If CompareEq NameLoad Str body Import alias Expr Call AttributeLoad NameLoad attr Expr Call NameLoad
N/A N/A 
Prepare the data for Genbank submission
 N/A os.path op N/A sys N/A string N/A logging collections defaultdict Bio SeqIO jcvi.utils.cbook memoized jcvi.utils.orderedcollections parse_qs jcvi.formats.base DictFile jcvi.apps.base OptionParser ActionDispatcher sh mkdir glob N/A 
GSS submission template files

<http://www.ncbi.nlm.nih.gov/dbGSS/how_to_submit.html>
 N/A Title Comparative Genomics of Sisymbrium irio N/A Authors Town,C.D., Tang,H., Paterson,A.H. and Pires,J.C. N/A Libname Sisymbrium irio BAC library SIL N/A Contact Chris D. Town N/A PublicationTemplate TYPE: Pub
MEDUID:
TITLE:
{Title}
AUTHORS:
{Authors}
JOURNAL:
VOLUME:
ISSUE:
PAGES:
YEAR: 2011
STATUS: 1
|| N/A LibraryTemplate TYPE: Lib
NAME: {Libname}
ORGANISM: Sisymbrium irio
STRAIN: Gomez-Campo 1146-67
SEX:
STAGE:
TISSUE:
CELL_TYPE:
VECTOR: pCC1BAC
RE_1: HindIII
DESCR:
Constructed by Amplicon Express;
Transformed into Invitrogen DH10b phage resistant E. coli.
|| N/A ContactTemplate TYPE: Cont
NAME: {Contact}
FAX: 301-795-7070
TEL: 301-795-7523
EMAIL: cdtown@jcvi.org
LAB: Plant Genomics
INST: J. Craig Venter Institute
ADDR: 9704 Medical Center Dr., Rockville, MD 20850, USA
|| N/A Directions N/A forward reverse TR TV N/A Primers N/A TR TV M13 Universal For 18bp Primer (TGTAAAACGACGGCCAGT) T7 Rev 20bp Primer (TAATACGACTCACTATAGGG) N/A GSSTemplate TYPE: GSS
STATUS: New
CONT_NAME: {Contact}
GSS#: {gssID}
CLONE: {cloneID}
SOURCE: JCVI
OTHER_GSS: {othergss}
CITATION:
{Title}
INSERT: 120000
PLATE: {plate}
ROW: {row}
COLUMN: {column}
SEQ_PRIMER: {primer}
DNA_TYPE: Genomic
CLASS: BAC ends
LIBRARY: {Libname}
PUBLIC:
PUT_ID:
COMMENT:
SEQUENCE:
{seq}
|| N/A N/A Nrows Ncols N/A 16 24 N/A vars N/A globals main N/A N/A N/A N/A N/A actions N/A N/A fcs process the results from Genbank contaminant screen N/A gss prepare package for genbank gss submission N/A htg prepare sqn to update existing genbank htg records N/A htgnew prepare sqn to submit new genbank htg records N/A asn get the name tags from a bunch of asn.1 files N/A t384 print out a table converting between 96 well to 384 well N/A p N/A ActionDispatcher actions N/A N/A N/A p dispatch N/A globals N/A fcs N/A N/A args N/A N/A N/A 
    %prog fcs fcsfile

    Process the results from Genbank contaminant screen. An example of the file
    looks like:

    contig name, length, span(s), apparent source
    contig0746      11760   1..141  vector
    contig0751      14226   13476..14226    vector
    contig0800      124133  30512..30559    primer/adapter
     N/A p N/A OptionParser N/A fcs __doc__ N/A N/A N/A p add_option --cutoff default 200 help Skip small components less than [default: %default] N/A N/A opts args N/A N/A p parse_args args N/A N/A N/A len args 1 N/A N/A N/A N/A sys exit N/A N/A N/A p print_help N/A N/A fcsfile args N/A cutoff N/A opts cutoff N/A fp N/A open fcsfile N/A row fp N/A N/A N/A N/A row N/A 0 # N/A N/A N/A sep N/A N/A row None N/A atoms N/A N/A N/A N/A row rstrip split sep 3 N/A N/A contig length N/A atoms N/A 2 N/A length N/A int length N/A label N/A atoms N/A -1 N/A label N/A N/A label replace _ N/A N/A N/A len atoms 3 N/A N/A ranges N/A N/A {0}..{1} format 1 length N/A N/A N/A N/A len atoms 4 N/A ranges N/A atoms N/A 2 N/A ab N/A N/A ranges split , N/A N/A N/A a b N/A N/A ab split .. N/A N/A a b N/A N/A int a N/A int b N/A N/A a b N/A ahang N/A a 1 N/A bhang N/A length b N/A N/A ahang cutoff N/A N/A a 1 N/A N/A bhang cutoff N/A N/A b length N/A N/A N/A join N/A N/A str x N/A x N/A contig N/A a 1 b label N/A asn N/A N/A args N/A N/A N/A 
    %prog asn asnfiles

    Mainly to get this block, and extract `str` field:

        general {
          db "TIGR" ,
          tag
            str "mtg2_12952" } ,
        genbank {
          accession "AC148996" ,
     jcvi.formats.base must_open N/A p N/A OptionParser N/A asn __doc__ N/A N/A N/A p set_outfile N/A N/A opts args N/A N/A p parse_args args N/A N/A N/A len args 1 N/A N/A N/A N/A sys exit N/A N/A N/A p print_help N/A fw N/A must_open N/A opts outfile w N/A asnfile args N/A N/A fp N/A open asnfile N/A ingeneralblock False N/A ingenbankblock False N/A N/A gb name N/A None None N/A row fp N/A N/A N/A N/A N/A row strip N/A N/A N/A tag N/A N/A N/A row split N/A 0 N/A N/A tag general N/A N/A ingeneralblock True N/A N/A ingeneralblock N/A tag str N/A N/A N/A name None N/A N/A name N/A N/A N/A row split " N/A 1 N/A ingeneralblock False N/A N/A tag genbank N/A N/A ingenbankblock True N/A N/A ingenbankblock N/A tag accession N/A N/A N/A gb None N/A N/A gb N/A N/A N/A row split " N/A 1 N/A ingenbankblock False N/A N/A gb name N/A fw N/A N/A {0}	{1} format gb name N/A verify_sqn N/A N/A sqndir accession N/A N/A N/A valfile N/A N/A {0}/{1}.val format sqndir accession N/A contents N/A N/A N/A N/A N/A open valfile read strip N/A N/A contents N/A N/A Validation error:
{0} format contents N/A cmd N/A N/A gb2fasta {0}/{1}.gbf format sqndir accession N/A outfile N/A N/A {0}/{1}.fasta format sqndir accession N/A N/A sh cmd outfile outfile N/A htgnew N/A N/A args N/A N/A N/A 
    %prog htgnew fastafile phasefile template.sbt

    Prepare sqnfiles for submitting new Genbank HTG records.

    `fastafile` contains the sequences.
    `phasefile` contains the phase information, it is a two column file:

    mth2-45h12    3

    `template.sbt` is the Genbank submission template.

    This function is simpler than htg, since the record names have not be
    assigned yet (so less bookkeeping).
     jcvi.formats.fasta sequin N/A p N/A OptionParser N/A htgnew __doc__ N/A N/A N/A p add_option --comment default help Comments for this submission [default: %default] N/A N/A opts args N/A N/A p parse_args args N/A N/A N/A len args 3 N/A N/A N/A N/A sys exit N/A N/A N/A p print_help N/A N/A fastafile phasefile sbtfile args N/A comment N/A opts comment N/A fastadir fasta N/A sqndir sqn N/A N/A mkdir fastadir N/A N/A mkdir sqndir N/A cmd N/A N/A faSplit byname {0} {1}/ format fastafile fastadir N/A N/A sh cmd outfile /dev/null errfile /dev/null N/A acmd tbl2asn -a z -p fasta -r {sqndir} N/A acmd  -i {splitfile} -t {sbtfile} -C tigr N/A acmd  -j "[tech=htgs {phase}] [organism=Medicago truncatula] [strain=A17]" N/A acmd  -o {sqndir}/{accession_nv}.sqn -V Vbr N/A acmd  -y "{comment}" -W T -T T N/A nupdated 0 N/A row N/A open phasefile N/A N/A N/A name phase N/A N/A N/A row split N/A 2 N/A fafile N/A N/A op join fastadir N/A name .fa N/A cloneopt N/A N/A --clone={0} format name N/A N/A splitfile gaps N/A sequin N/A fafile cloneopt N/A splitfile N/A N/A op basename splitfile N/A accession accession_nv name N/A phase N/A int phase N/A N/A phase N/A 1 2 3 N/A cmd N/A N/A acmd format accession_nv accession_nv sqndir sqndir sbtfile sbtfile splitfile splitfile phase phase comment comment N/A N/A sh cmd N/A N/A verify_sqn sqndir accession N/A nupdated 1 N/A N/A sys stderr N/A N/A A total of {0} records updated. format nupdated N/A htg N/A N/A args N/A N/A N/A 
    %prog htg fastafile template.sbt

    Prepare sqnfiles for Genbank HTG submission to update existing records.

    `fastafile` contains the records to update, multiple records are allowed
    (with each one generating separate sqn file in the sqn/ folder). The record
    defline has the accession ID. For example,
    >AC148290.3

    Internally, this generates two additional files (phasefile and namesfile)
    and download records from Genbank. Below is implementation details:

    `phasefile` contains, for each accession, phase information. For example:
    AC148290.3      3       HTG     2       mth2-45h12

    which means this is a Phase-3 BAC. Record with only a single contig will be
    labeled as Phase-3 regardless of the info in the `phasefile`. Template file
    is the Genbank sbt template. See jcvi.formats.sbt for generation of such
    files.

    Another problem is that Genbank requires the name of the sequence to stay
    the same when updating and will kick back with a table of name conflicts.
    For example:

    We are unable to process the updates for these entries
    for the following reason:

    Seqname has changed

    Accession Old seq_name New seq_name
    --------- ------------ ------------
    AC239792 mtg2_29457 AC239792.1

    To prepare a submission, this script downloads genbank and asn.1 format,
    and generate the phase file and the names file (use formats.agp.phase() and
    apps.gbsubmit.asn(), respectively). These get automatically run.

    However, use --phases if the genbank files contain outdated information.
    For example, the clone name changes or phase upgrades. In this case, run
    formats.agp.phase() manually, modify the phasefile and use --phases to override.
     jcvi.formats.fasta sequin ids jcvi.formats.agp phase jcvi.apps.fetch entrez N/A p N/A OptionParser N/A htg __doc__ N/A N/A N/A p add_option --phases default None help Use another phasefile to override [default: %default] N/A N/A N/A p add_option --comment default help Comments for this update [default: %default] N/A N/A opts args N/A N/A p parse_args args N/A N/A N/A len args 2 N/A N/A N/A N/A sys exit N/A N/A N/A p print_help N/A N/A fastafile sbtfile args N/A pf N/A N/A N/A fastafile rsplit . 1 N/A 0 N/A idsfile N/A pf .ids N/A phasefile N/A pf .phases N/A namesfile N/A pf .names N/A N/A ids N/A fastafile N/A N/A --outfile={0} format idsfile N/A asndir asn.1 N/A N/A mkdir asndir N/A N/A entrez N/A idsfile --format=asn.1 N/A N/A --outdir={0} format asndir N/A N/A asn N/A N/A glob N/A N/A {0}/* format asndir N/A N/A N/A --outfile={0} format namesfile N/A N/A N/A opts phases None N/A N/A gbdir gb N/A N/A mkdir gbdir N/A N/A entrez N/A idsfile --format=gb N/A N/A --outdir={0} format gbdir N/A N/A phase N/A N/A glob N/A N/A {0}/* format gbdir N/A N/A N/A --outfile={0} format phasefile N/A N/A phasefile N/A opts phases N/A N/A N/A N/A op exists namesfile N/A N/A op exists phasefile N/A newphasefile N/A phasefile .new N/A newphasefw N/A open newphasefile w N/A comment N/A opts comment N/A fastadir fasta N/A sqndir sqn N/A N/A mkdir fastadir N/A N/A mkdir sqndir jcvi.graphics.histogram stem_leaf_plot N/A names N/A DictFile namesfile N/A N/A N/A len N/A set N/A N/A names keys N/A len N/A set N/A N/A names values N/A phases N/A DictFile phasefile N/A ph N/A N/A int x N/A x N/A N/A phases values N/A N/A stem_leaf_plot ph 1 4 3 title Counts of phases before updates N/A N/A N/A logging debug N/A N/A Information loaded for {0} records. format N/A len phases N/A N/A N/A len names N/A len phases N/A newph N/A N/A cmd N/A N/A faSplit byname {0} {1}/ format fastafile fastadir N/A N/A sh cmd outfile /dev/null errfile /dev/null N/A acmd tbl2asn -a z -p fasta -r {sqndir} N/A acmd  -i {splitfile} -t {sbtfile} -C tigr N/A acmd  -j "{qualifiers}" N/A acmd  -A {accession_nv} -o {sqndir}/{accession_nv}.sqn -V Vbr N/A acmd  -y "{comment}" -W T -T T N/A qq [tech=htgs {phase}] [organism=Medicago truncatula] [strain=A17] N/A nupdated 0 N/A row N/A open phasefile N/A N/A atoms N/A N/A N/A N/A row rstrip split N/A N/A accession phase clone N/A N/A atoms N/A 0 N/A atoms N/A 1 N/A atoms N/A -1 N/A fafile N/A N/A op join fastadir N/A accession .fa N/A accession_nv N/A N/A N/A accession split . 1 N/A 0 N/A newid N/A names N/A accession_nv N/A newidopt N/A N/A --newid={0} format newid N/A cloneopt N/A N/A --clone={0} format clone N/A N/A splitfile gaps N/A sequin N/A fafile newidopt cloneopt N/A splitfile N/A N/A op basename splitfile N/A phase N/A int phase N/A N/A phase N/A 1 2 3 N/A oldphase phase N/A N/A N/A gaps 0 N/A phase 3 N/A N/A phase 3 N/A N/A N/A gaps 0 N/A phase 3 N/A N/A phase 2 N/A newphasefw N/A N/A {0}	{1}	{2} format accession_nv oldphase phase N/A N/A N/A newph append phase N/A qualifiers N/A N/A qq format phase phase N/A N/A ; clone N/A N/A qualifiers  [keyword=HTGS_POOLED_MULTICLONE] N/A cmd N/A N/A acmd format accession accession accession_nv accession_nv sqndir sqndir sbtfile sbtfile splitfile splitfile qualifiers qualifiers comment comment N/A N/A sh cmd N/A N/A verify_sqn sqndir accession N/A nupdated 1 N/A N/A stem_leaf_plot newph 1 4 3 title Counts of phases after updates N/A N/A sys stderr N/A N/A A total of {0} records updated. format nupdated N/A get_rows_cols N/A N/A nrows ncols N/A Nrows Ncols N/A N/A N/A rows cols N/A N/A N/A string ascii_uppercase N/A nrows N/A range 1 N/A ncols 1 N/A N/A rows cols N/A memoized get_plate N/A N/A nrows ncols N/A Nrows Ncols N/A N/A N/A rows cols N/A get_rows_cols nrows ncols N/A plate N/A N/A N/A ncols N/A x N/A xrange nrows N/A n 0 N/A i N/A xrange 0 nrows 2 N/A N/A j N/A xrange 0 ncols 2 N/A N/A n 1 N/A prefix N/A N/A {0:02d} format n N/A N/A N/A plate N/A i N/A j N/A prefix A N/A N/A N/A plate N/A i N/A N/A j 1 N/A prefix B N/A N/A N/A plate N/A N/A i 1 N/A j N/A prefix C N/A N/A N/A plate N/A N/A i 1 N/A N/A j 1 N/A prefix D N/A splate N/A N/A i N/A xrange nrows N/A N/A j N/A xrange ncols N/A N/A c N/A N/A plate N/A i N/A j N/A N/A splate N/A c N/A N/A {0}{1} format N/A rows N/A i N/A j 1 N/A N/A plate splate N/A memoized convert_96_to_384 N/A N/A c96 quad nrows ncols N/A Nrows Ncols N/A N/A 
    Convert the 96-well number and quad number to 384-well number

    >>> convert_96_to_384("B02", 1)
    'C3'
    >>> convert_96_to_384("H09", 4)
    'P18'
     N/A N/A rows cols N/A get_rows_cols N/A N/A plate splate N/A get_plate N/A n96 N/A N/A N/A N/A N/A rows index N/A c96 N/A 0 ncols 2 N/A int N/A c96 N/A 1 N/A q N/A N/A {0:02d}{1} format n96 N/A ABCD N/A N/A quad 1 N/A N/A splate N/A q N/A t384 N/A N/A args N/A N/A N/A 
    %prog t384

    Print out a table converting between 96 well to 384 well
     N/A p N/A OptionParser N/A t384 __doc__ N/A N/A opts args N/A N/A p parse_args args N/A N/A plate splate N/A get_plate N/A fw N/A sys stdout N/A i plate N/A N/A N/A j p N/A enumerate i N/A N/A N/A j 0 N/A N/A N/A N/A fw write | N/A N/A N/A fw write p N/A N/A N/A fw write N/A parse_description N/A N/A s N/A N/A N/A 
    Returns a dictionary based on the FASTA header, assuming JCVI data
     N/A s N/A N/A N/A N/A join N/A N/A N/A s split N/A 1 replace / ; N/A a N/A parse_qs s N/A a N/A gss N/A N/A args N/A N/A N/A 
    %prog gss fastafile plateMapping

    Generate sequence files and metadata templates suited for gss submission.
    The FASTA file is assumed to be exported from the JCVI data delivery folder
    which looks like:

    >1127963806024 /library_name=SIL1T054-B-01-120KB /clear_start=0
    /clear_end=839 /primer_id=1049000104196 /trace_id=1064147620169
    /trace_file_id=1127963805941 /clone_insert_id=1061064364776
    /direction=reverse /sequencer_run_id=1064147620155
    /sequencer_plate_barcode=B906423 /sequencer_plate_well_coordinates=C3
    /sequencer_plate_96well_quadrant=1 /sequencer_plate_96well_coordinates=B02
    /template_plate_barcode=CC0251602AB /growth_plate_barcode=BB0273005AB
    AGCTTTAGTTTCAAGGATACCTTCATTGTCATTCCCGGTTATGATGATATCATCAAGATAAACAAGAATG
    ACAATGATACCTGTTTGGTTCTGAAGTGTAAAGAGGGTATGTTCAGCTTCAGATCTTCTAAACCCTTTGT
    CTAGTAAGCTGGCACTTAGCTTCCTATACCAAACCCTTTGTGATTGCTTCAGTCCATAAATTGCCTTTTT

    Plate mapping file maps the JTC `sequencer_plate_barcode` to external IDs.
    For example:
    B906423 SIL-001
     N/A p N/A OptionParser N/A gss __doc__ N/A N/A opts args N/A N/A p parse_args args N/A N/A N/A len args 2 N/A N/A N/A N/A sys exit N/A N/A p print_help N/A N/A fastafile mappingfile args N/A seen N/A defaultdict int N/A clone N/A defaultdict set N/A plateMapping N/A DictFile mappingfile N/A fw N/A open MetaData.txt w N/A fw N/A N/A PublicationTemplate format vars N/A fw N/A N/A LibraryTemplate format vars N/A fw N/A N/A ContactTemplate format vars N/A N/A N/A logging debug N/A N/A Meta data written to `{0}` format N/A fw name N/A fw N/A open GSS.txt w N/A fw_log N/A open GSS.log w N/A rec N/A N/A SeqIO parse fastafile fasta N/A N/A description N/A rec description N/A a N/A parse_description description N/A direction N/A N/A a N/A direction N/A 0 N/A sequencer_plate_barcode N/A N/A a N/A sequencer_plate_barcode N/A 0 N/A sequencer_plate_well_coordinates N/A N/A a N/A sequencer_plate_well_coordinates N/A 0 N/A sequencer_plate_96well_quadrant N/A N/A a N/A sequencer_plate_96well_quadrant N/A 0 N/A sequencer_plate_96well_coordinates N/A N/A a N/A sequencer_plate_96well_coordinates N/A 0 N/A w96 sequencer_plate_96well_coordinates N/A w96quad N/A int sequencer_plate_96well_quadrant N/A w384 sequencer_plate_well_coordinates N/A N/A N/A convert_96_to_384 w96 w96quad w384 N/A plate sequencer_plate_barcode N/A N/A plate plateMapping N/A N/A {0} not found in `{1}` ! format plate mappingfile N/A plate N/A plateMapping N/A plate N/A d N/A Directions N/A direction N/A cloneID N/A N/A {0}{1} format plate w384 N/A gssID N/A N/A {0}{1} format cloneID d N/A N/A seen N/A gssID 1 N/A N/A N/A seen N/A gssID 1 N/A N/A gssID N/A N/A {0}{1} format gssID N/A seen N/A gssID N/A N/A seen N/A gssID 1 N/A N/A N/A N/A clone N/A cloneID add gssID N/A seen N/A defaultdict int N/A rec N/A N/A SeqIO parse fastafile fasta N/A N/A description N/A rec description N/A a N/A parse_description description N/A direction N/A N/A a N/A direction N/A 0 N/A sequencer_plate_barcode N/A N/A a N/A sequencer_plate_barcode N/A 0 N/A sequencer_plate_well_coordinates N/A N/A a N/A sequencer_plate_well_coordinates N/A 0 N/A w384 sequencer_plate_well_coordinates N/A plate sequencer_plate_barcode N/A plate N/A plateMapping N/A plate N/A d N/A Directions N/A direction N/A cloneID N/A N/A {0}{1} format plate w384 N/A gssID N/A N/A {0}{1} format cloneID d N/A N/A seen N/A gssID 1 N/A N/A N/A seen N/A gssID 1 N/A N/A N/A N/A logging error N/A N/A duplicate key {0} found format gssID N/A gssID N/A N/A {0}{1} format gssID N/A seen N/A gssID N/A othergss N/A N/A clone N/A cloneID N/A set N/A gssID N/A othergss N/A N/A ,  join N/A sorted othergss N/A N/A N/A vars update N/A locals N/A fw N/A N/A GSSTemplate format vars N/A fw_log N/A N/A {0}	{1} format gssID description N/A fw_log N/A = 60 N/A N/A N/A logging debug N/A N/A A total of {0} seqs written to `{1}` format N/A len seen N/A fw name N/A N/A N/A fw close N/A N/A N/A fw_log close N/A N/A N/A __name__ __main__ N/A N/A doctest N/A N/A N/A doctest testmod N/A N/A main