PyDNAutil module¶
Created on Wed May 18 14:06:37 2016
@author: yzj
-
PyDNAutil.
ALPHABET
= 'ACGT'¶ Used for process original data.
-
PyDNAutil.
Frequency
(tol_str, tar_str)[source]¶ Generate the frequency of tar_str in tol_str.
Parameters: - tol_str – mother string.
- tar_str – substring.
-
PyDNAutil.
GeneratePhycheValue
(k, phyche_index=None, all_property=False, extra_phyche_index=None)[source]¶ Combine the user selected phyche_list, is_all_property and extra_phyche_index to a new standard phyche_value. #################################################################
-
PyDNAutil.
GetData
(input_data, desc=False)[source]¶ Get sequence data from file or list with check.
Parameters: - input_data – type file or list
- desc – with this option, the return value will be a Seq object list(it only works in file object).
Returns: sequence data or shutdown.
-
PyDNAutil.
GetSequenceCheckDna
(f)[source]¶ Read the fasta file.
Input: f: HANDLE to input. e.g. sys.stdin, or open(<file>)
-
PyDNAutil.
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.
-
PyDNAutil.
IsSequenceList
(sequence_list)[source]¶ Judge the sequence list is within the scope of alphabet and change the lowercase to capital. #################################################################
-
PyDNAutil.
IsUnderAlphabet
(s, alphabet)[source]¶ Judge the string is within the scope of the alphabet or not.
Parameters: - s – The string.
- alphabet – alphabet.
-
PyDNAutil.
ReadFasta
(f)[source]¶ Read a fasta file.
Parameters: f – HANDLE to input. e.g. sys.stdin, or open(<file>)
-
PyDNAutil.
ReadFastaCheckDna
(f)[source]¶ Read the fasta file, and check its legality.
Parameters: f – HANDLE to input. e.g. sys.stdin, or open(<file>)