Skip navigation

Category Archives: Coding

Nel mondo anglosassone non ci sono soprese dentro alle uova di Pasqua, ma sono proprio le uova le soprese da trovare. Per questo buffe funzionalità nascoste nei programmi sono chiamate Easter eggs. Per augurare buona Pasqua non infilerò scherzetti nei programmi bioinformatici, ma rilascio l’implementazione in Perl semplice semplice dell’algoritmo più usato per calcolare la data di Pasqua in un dato anno.

The code is also here

Read More »

Ruzzle SolverBioinformatics can help with Ruzzle game too. I prepared a simple online ruzzle solver, where you simply enter the 16 character of the Ruzzle square, choose which language between Italian and English (Deutsch and Espagnol coming soon) and hit enter to see all possible words.

Update (31 jan 2013): a new version using AJAX is online, and more than 200% faster than the first release. Thanks to the hundreds daily users!

Ruzzle SolverCome passatempo mi sono divertito a scrivere un piccolo online ruzzle solver, dove basta inserire lo schema di caratteri per ottenere le parole che si celano nel gioco.

Aggiornamento (31 jan 2013): Passando ad AJAX la velocità del sito è aumentata di oltre il 200%… Grazie a tutti gli utilizzatori per i feedback!

When I need to merge multiple alignment files (in BAM format) I adopted this pipeline: extract the header from one of the files, then printing all the BAM files into the same SAM file.

samtools view -H one-of-the-files.sam > mergedfile.sam
find . -name "*.bam" -exec samtools view {} \; >> mergedfile.sam
samtools view -bh mergedfile.sam > mergedfile.bam

 

syntax_perlWhen in the need of sending a syntax-colored version of a perl snippet, I published a very simple and easy tool that paints the code for you.

The syntax highlighter, of course, is in Perl…

http://telatin.com/tools/perl2code.html

Ajax is a powerful technology and it’s also really easy to code (probably this is the reason why often webmasters abuse of it). The general concept it’s easy: you have a program or scriptthat can dinamically produce some output of interest. You have a web page, that will embed this output inside of it, without refreshing. The magic is made with a new JavaScript object called HTTPRequest. Read More »