Info | Home
BioPHP - Functions
BioPHP - Functions
alignment_of_dna
Alignment of two DNA sequences.
Smith-Waterman alignment method is used.
alignment_of_proteins
Alignment of two protein sequences.
Smith-Waterman alignment method is used.
basic_tm
Basic melting (Tm) temperature foroligonucleotides
chemgrp_protein
Translates peptide sequence to checmical groups.
Chemical groups/aminoacids:
L/GAVLI
H/ST
M/NQ
R/FYW
S/CM
I/P
A/DE
C/KRH
*/*
X/X
complement
Gets the genetic complement of a DNA or RNA sequence.
count_codons_dna_or_rna
Counts the number of codons (trios of base-pairs) in a DNA/RNA sequence.
dna_is_palindrome
This is my proposal to substitute is_palindrome function from GenePHP. I
have just tried to make it simple.
By using function RevComp_DNA2 it allows searching within sequences with
degenerated nucleotides
Although its length is not odd, a pattern like TATANTATA will be
considered palindromic
Uses function RevComp_DNA2
dna_remove_non_coding
Removes non coding characters from DNA sequence. Degenerated nucleotides
are not removed.
dna_to_protein
Translates DNA to protein by using one of the 13 genetic codes described.
expand_na
Returns the expansion of a nucleic acid sequence, replacing special
wildcard symbols with the proper PERL regular expression.
find_palindromic_seqs
Searches for palindromic sequences within a DNA sequence.
Length of palindromic sequences to be searched will be between $min and
$max values
Will return an array with key = start position and val= palindromic
sequence
Requires function DNA_is_palindrome
find_tandem_repeats
Searches for tandem repeats within a DNA sequence.
A tandem repeat is a sequence with contains a pattern repeated several
times
as for example in AAAAAgtagtagtagtagtagtagtTTTTTTTTT, which contains a
tandem repeat (subsequence GTA repeated 6 times). Tandem repeats may
suffer insertions and deletions afecting the number of times the pattern
is repeated. When amplifying by PCR the tandem repeat and the sequence
around them, different strains will probably yield bands with different
lengths.
Comparison of patterns allows their usage for epidemiology porpoises
$sequence is the DNA sequence to be searched
$min_length is the minimum length of repeated pattern (must be >2)
$max_length is the maximum length of repeated pattern
$min_repeats is the minimum number of times the pattern must be
repeated
$min_length_of_TR is the minimum length of the tandem repeat
Example:
find_tandem_repeats(\"AAAAAgtagtagtagtagtagtagtTTTTTTTTT\",2,6,3,15)
Result: Array(
[0] => Array(
[start_position] => 5
[pattern] => gta
[number_of_repeats] => 6
[tandem_repeat_sequence] => gtagtagtagtagtagtagt
))
This function does not allow errors within repeated pattern
(with are detected by programs specificaly designed to search for tandem
repeat)
gc_content
Computes G+C content of DNA sequence
get_bridge
Returns the sequence located between two palindromic halves of a
palindromic string.
Take note that the \"bridge\" as I call it, is not necessarily a genetic
mirror or a palindrome.
get_oligos_from_pattern
Will response with sequences recognized by a oligo pattern.
If oligo does not include degenerate nucleotides response will be the same
oligo
example: oligo is TATA, and response will be TATA
If oligo includes degenerate nucleotides response will be comma separated
sequences
example: oligo is WATW, and response will be AATA,AATT,TATA,TATT
halfstr
Returns one of the two palindromic \"halves\" of a palindromic string.
identify_aminoacid
Returns complete name of aminoacid. Input may be one or three letter code.
molwt_nucleic_acid
Calculates the molecular weight of a nucleic acid.
From GenePHP, seq.php, class seq
molwt_protein
Computes the molecular weight of a protein sequence.
nucleotide_composition
Calculates nucleotide composition of sequences.
nucleotide_identification
Returns name of nucleotide. P.e., for A, returns \"Adenosine\".
Degenerated nucleotides are also identified. P.e., for R, returns \"Purine
(A & G)\"
number_of_matching_sequences
Will response with number of sequences matching a oligo.
If oligo does not include degenerate nucleotides response will be 1.
example: oligo is TATA, and response will be 1
If oligo includes degenerated nucleotides response will be >1
.
example: oligo is WATW, and response will be 4 (recognizes:
AATA,AATT,TATA,TATT
protein_to_dna
Reverse translation of protein to DNA by using one fo the 13 genomic codes
described.
random_dna
Generates a random DNA sequence. Number of A, C, G and T must be provided.
revcomp
First gets the complement of a DNA or RNA sequence, and then returns it in
reverse order.
Uses the function complement
revcomp_dna
Returns Reverse-Complement of DNA sequence. It is similar to revcomp
function in GenePHP (in etc.php file), but the speed is about 6x faster.
revcomp_dna2
This function is derived from RevComp_DNA function. I think it may be
interesting to maintaing RevComp_DNA and RevComp_DNA2 as two separated
functions; for
big sequences, the functions may be selected depending on needs.
This function allows transforming the sequence when degenerated
nucleotides are present.
salt_adjusted_tm
Salt_Adjusted Melting Temperature (Tm) Calculations
$salt: monovalent cations concentration([K+] + [Na+]), mM
seq_to_pattern_with_uib
Transforms a DNA sequence into a pattern
Example: from RCGY to [AG]CG[CT]
seqlen
Returns the length of a sequence
stats_factorial
Computes factorial of number
stats_mean
Will calculate the mean of a serie of numbers.
stats_regression_correlation
Computes standard curve (y=ax+b) and correlation coefficient (r).
stats_standard_deviation
Calculates Standard Deviation of a serie of numbers
stats_variance
Calculates varience of a serie of numbers
subseq
Return subsequence of sequence based in start and length of subsequence
translate_codon
Translate a codon to correspondin aminoacid.
If $format=3, a three letter aminoacid named is obtained.
If $format=1, a one letter aminoacid named is obtained