Posts

Showing posts with the label bioinformatic

DNA fractals

Image
Some days ago, I had a talk with I who suggested me to use some mathematical approaches to compare artificial with real sequences (one of my projects). Besides mutual information and SVM classification systems, he told me about fractals presents in the sequences. The method had been called "Chaos game for DNA" ( emboss has a subprogram to do it named chaos ) and the algorithm is very simple: use a square with each corner represents a "letter" (AGCT), start in the middle of the square and read the sequence, you add a point in the halfway of the previous point and the new letter, continue until you finish the sequence This method was previously described in the 90's, recently we have more genome information to continue exploring this characteristic in the DNA sequence, some application include alignment-free comparison and other iterative systems which reproduce this effect. After I plot some sequences, I asked me to test other species to see differences, but a...

Tips And Tricks For Bioinformatics Software Engineering

Gus told me about this blog post which is the condensed version of this presentation: Tips And Tricks For Bioinformatics Software Engineering View more presentations from jtdudley . (tags: bioinformaticsprogrammin ... bioinformatics ) Let's discuss some points: Learn UNIX . This is basic, many people comes from the MS-world and wants to do the same tasks as in UNIX, wrong , the UNIX philosophy and design is optimized for heavy task and multiple activities, besides the complete support for programming, servers, administration, ... I say: don't waste your time, use UNIX (Linux, Mac OS, BSD, Solaris, ...). Know many computer languages but be master in ONE . In this part the talk is focused in Java/Python/Ruby, I still suggest Perl. Perl big problem is the object-oriented pragma , but nothing compares the power of regular expressions and text-parsing of Perl. Besides Perl is less grammar strict than Java/Python, it's easy to learn but easy to acquire bad habits. Don’t reinv...

Filtering common miRNAs

Last day, M asks me how to compact the microRNA mature fasta-file from miRbase , the problem is many miRNA are conservated across species, so the fasta file with all the mature sequences has a lot of redundancy and he wants unique sequences to screen some sequences. This is a simple Perl solution, the first step is to read and collect the sequences, the trick is to save in a hash using the nucleic sequences as "key" and append the names as "value". After this, simply extract the "keys" and parse a little the "values" to have a common identifier. Code: #!/usr/bin/perl -w use strict; =head1 NAME uniq_mir.pl FASTA =head1 DESCRIPTION Filter the multifasta file of miRbase (mature.fa) into unique miR by sequence. =cut $ARGV[0] or die "Usage: uniq_mir.pl FASTA\n"; my $name = ''; my %seqs = (); open F, "$ARGV[0]" or die "cannot open $ARGV[0]\n"; while ( <F>) { chomp; if (/^>/) { s/>//; my @line = ...

Bioinfomatic in web2.0

DNASIS SmartNote is an on-line service for bioinformatic analysis integration, currently it's like Google Docs but specific for bioinformatic, it looks good and very expandable, it includes some basic tools: Similarity Blast - NCBI Statistics Codon Usage CpG Islands DNA Stats Hetero Dimer - IDT Oligo Analyzer Oligo Analyzer - IDT PCR Primer Stats Protein Stats Translation/complement Reverse Complement Reverse Translation Translate Tool - ExPASy Alignment ClustalW - EBI Multiple Alignment Editor - Jalview MUSCLE - EBI Pairwise Alignment - EBI EMBOSS T-Coffee - EBI Annotations/search Blast - NCBI CpG Islands DNA Pattern Find Fuzzy DNA Search Fuzzy Protein Search Neural Network Promoter Prediction ORF Finder Primer Map Protein Pattern Find ...

Perl recursion for oligo creation

#!/usr/bin/perl -w use strict; =head1 NAME oligoGenerator.pl =head1 DESCRIPTION Perl script to generate all possible combinations of size k using an alphabet @a, we use function recursion. My intention is to create all possible oligonucleotides (DNA alphabet or ACGT) but can be extended to any other field using a different alphabet. Output also can be printed in other forms, you can put other delimiters in the push function or in the final array printed. =cut my ($k) = 4; # definition of the word size my @a = qw/A C G T/; # definition of the alphabet my @words = createWords($k, @a);# main function print join("\n", @words), "\n"; # print output sub createWords { my $k = shift @_; $k--; my @old = @_; my @new = (); if ($k < 1) { return @old; } else { foreach my $e (@old) { foreach my $n (@a) { push @new, "$e$n"; # add new element } } createWords($k, @new); # recursion c...

Simple assembly

Image
Last week my good friend M asks me to create a script to draw some sequences, the main problem is to visually see differences in transcript orientation (sense and antisense), some time ago I created similar tools for mapping short sequences like 454 pyro or siRNAs. Now the big problem is to have a good assembly, many regions can extend a "contig" to the left or the right, so internal coordinates change every time you add a new element, with short sequences you have a target well defined and the extension is relative to it. After thinking a little, I decide not extend my code to the assembly (yes, I'm lazy) and use Phrap to perform the job. A parser read the output and extract the alignment information. Second problem was the fasta naming convention, the original fasta file is a mixed names of other sequences, so I decided to create and tag an unique ID, "seq_##". Extending the problem, M asks me to be possible to add more sequences, based in the sequence homolo...

Bioinformatics Career Survey 2008

Image
Bioinformatics Zen had released the results in a text-file of the Bioinformatic Career Survey 2008 , the survey include data from ~650 people from academia and industry, it's interesting to take a look in the data, I summarize this in some graphics: Career Background Bioinformatics area Computer Language

BioMath

Image
The Defense Advance Research Projects Agency ( DARPA ) is offering support for resolve 23 mathematical problems, you can read the full rules here (sorry it's a DOC). This is the problems they want to solve: The Mathematics of the Brain . Develop a mathematical theory to build a functional model of the brain that is mathematically consistent and predictive rather than merely biologically inspired. The Dynamics of Networks. Develop the high-dimensional mathematics needed to accurately model and predict behavior in large-scale distributed networks that evolve over time occurring in communication, biology and the social sciences. Capture and Harness Stochasticity in Nature. Address Mumford’s call for new mathematics for the 21st century. Develop methods that capture persistence in stochastic environments. 21st Century Fluids. Classical fluid dynamics and the Navier -Stokes Equation were extraordinarily successful in obtaining quantitative understanding of shock waves, turbulence an...

Bioinfo tips

Yesterday I was disturbed of my coding-state to answer a basic problem, which's the best font to display a sequences alignment? First introduce the concept of sequence alignment, if you want to compare 2 or more sequences in their composition of nucleic bases (for DNA or RNA) or amino acid (for peptids ), you must search similar blocks between all the context and try to fix the rest as possible. Many algorithms has been created to perform this task, with different approaches, if you want to know more, please go to Wikipedia or bioinformatics books. Ok , let's consider we have our alignment, really this is a text file with a special structure to easy visualize the blocks found. Some people make the mistake to cut-and-paste in a text document without change the font style, a font is just an image to represent letters or symbols, some are very artistic but generally the font does not conserve a proportional aspect in size, so the beautiful alignment changes its proportion and vi...