GetDNA module

This module is used for downloading the DNA sequence from ncbi web. You can only

need input a DNA ID.

Authors: Zhijiang Yao and Dongsheng Cao.

Date: 2016.11.04

Email: gadsby@163.com

GetDNA.GetDNAFromUniGene(SeqID='')[source]

This module is used for downloading the DNA sequence from ncbi web. You can only

need input a DNA ID.

GetDNA.IsFasta(seq)[source]

Judge the Seq object is in FASTA format. Two situation: 1. No seq name. 2. Seq name is illegal. 3. No sequence.

Parameters:seq – Seq object.
GetDNA.IsUnderAlphabet(s, alphabet)[source]

Judge the string is within the scope of the alphabet or not.

Parameters:
  • s – The string.
  • alphabet – alphabet.
GetDNA.ReadFasta(f)[source]

Read a fasta file.

Parameters:f – HANDLE to input. e.g. sys.stdin, or open(<file>)
class GetDNA.Seq(name, seq, no)[source]