Sunday, July 6, 2014

Creating Perl Modules

How to create a Perl Module for code reuse?

http://perlmaven.com/how-to-create-a-perl-module-for-code-reuse

José's Guide for creating Perl modules

http://www.perlmonks.org/?node_id=431702

Simple Module Tutorial

http://www.perlmonks.org/?node_id=102347

Thursday, July 3, 2014

What is principal component analysis?

A really good post by Lior Pachter
http://liorpachter.wordpress.com/2014/05/26/what-is-principal-component-analysis/

Print specific column of a text file

To print the second last column of a tab delimited file,

awk -F '\t' '{print $(NF-1)}' file

NF is a special awk variable that contains the number of fields in the current record.

Merge multiple text files while deleting the first line of all files

tail -q -n +2 file1 file2 file3

Reference
http://stackoverflow.com/questions/10103619/unix-merge-many-files-while-deleting-first-line-of-all-files