How Do I Install CD-HIT on Ubuntu

CD-HIT is a popular bioinformatics software for clustering and comparing protein or nucleotide sequences. Although I downloaded the CD-HIT and followed the instruction in CD-HIT manual but it doesn't work for me. Then I decided to download CD-HIT directly from Ubuntu software center. Only a single command worked like a charm for me<
sudo apt-get install cd-hit

Remember when I tried to run this command apt-get install cd-hit I got an error like this
E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
So just avoid the mistake I did. So after running this command I got this success message
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  linux-headers-3.13.0-32 linux-headers-3.13.0-32-generic
  linux-image-3.13.0-32-generic linux-image-extra-3.13.0-32-generic
Use 'apt-get autoremove' to remove them.
The following NEW packages will be installed:
  cd-hit
0 upgraded, 1 newly installed, 0 to remove and 3 not upgraded.
Need to get 701 kB of archives.
After this operation, 1,316 kB of additional disk space will be used.
Get:1 http://us.archive.ubuntu.com/ubuntu/ trusty/universe cd-hit amd64 4.6.1-2012-08-27-2 [701 kB]
Fetched 701 kB in 1s (507 kB/s) 
Selecting previously unselected package cd-hit.
(Reading database ... 306437 files and directories currently installed.)
Preparing to unpack .../cd-hit_4.6.1-2012-08-27-2_amd64.deb ...
Unpacking cd-hit (4.6.1-2012-08-27-2) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Processing triggers for doc-base (0.10.5) ...
Processing 1 added doc-base file...
Setting up cd-hit (4.6.1-2012-08-27-2) ...

I got this option when I run the cd-hit-est from my root
        ====== CD-HIT version 4.6 (built on Oct 21 2013) ======

Usage: cdhit-est [Options] 

Options

   -i        input filename in fasta format, required
   -o        output filename, required
   -c        sequence identity threshold, default 0.9
         this is the default cd-hit's "global sequence identity" calculated as:
         number of identical amino acids in alignment
         divided by the full length of the shorter sequence
   -G        use global sequence identity, default 1
         if set to 0, then use local sequence identity, calculated as :
         number of identical amino acids in alignment
         divided by the length of the alignment
         NOTE!!! don't use -G 0 unless you use alignment coverage controls
         see options -aL, -AL, -aS, -AS
   -b        band_width of alignment, default 20
   -M        memory limit (in MB) for the program, default 800; 0 for unlimitted;
   -T        number of threads, default 1; with 0, all CPUs will be used
   -n        word_length, default 10, see user's guide for choosing it
   -l        length of throw_away_sequences, default 10
   -d        length of description in .clstr file, default 20
         if set to 0, it takes the fasta defline and stops at first space
   -s        length difference cutoff, default 0.0
         if set to 0.9, the shorter sequences need to be
         at least 90% length of the representative of the cluster
   -S        length difference cutoff in amino acid, default 999999
         if set to 60, the length difference between the shorter sequences
         and the representative of the cluster can not be bigger than 60
   -aL        alignment coverage for the longer sequence, default 0.0
         if set to 0.9, the alignment must covers 90% of the sequence
   -AL        alignment coverage control for the longer sequence, default 99999999
         if set to 60, and the length of the sequence is 400,
         then the alignment must be >= 340 (400-60) residues
   -aS        alignment coverage for the shorter sequence, default 0.0
         if set to 0.9, the alignment must covers 90% of the sequence
   -AS        alignment coverage control for the shorter sequence, default 99999999
         if set to 60, and the length of the sequence is 400,
         then the alignment must be >= 340 (400-60) residues
   -A        minimal alignment coverage control for the both sequences, default 0
         alignment must cover >= this value for both sequences 
   -uL        maximum unmatched percentage for the longer sequence, default 1.0
         if set to 0.1, the unmatched region (excluding leading and tailing gaps)
         must not be more than 10% of the sequence
   -uS        maximum unmatched percentage for the shorter sequence, default 1.0
         if set to 0.1, the unmatched region (excluding leading and tailing gaps)
         must not be more than 10% of the sequence
   -U        maximum unmatched length, default 99999999
         if set to 10, the unmatched region (excluding leading and tailing gaps)
         must not be more than 10 bases
   -B        1 or 0, default 0, by default, sequences are stored in RAM
         if set to 1, sequence are stored on hard drive
         it is recommended to use -B 1 for huge databases
   -p        1 or 0, default 0
         if set to 1, print alignment overlap in .clstr file
   -g        1 or 0, default 0
         by cd-hit's default algorithm, a sequence is clustered to the first 
         cluster that meet the threshold (fast cluster). If set to 1, the program
         will cluster it into the most similar cluster that meet the threshold
         (accurate but slow mode)
         but either 1 or 0 won't change the representatives of final clusters
   -r        1 or 0, default 1, by default do both +/+ & +/- alignments
         if set to 0, only +/+ strand alignment
   -mask        masking letters (e.g. -mask NX, to mask out both 'N' and 'X')
   -match        matching score, default 2 (1 for T-U and N-N)
   -mismatch        mismatching score, default -2
   -gap        gap opening score, default -6
   -gap-ext        gap extension score, default -1
   -bak        write backup cluster file (1 or 0, default 0)
   -h        print this help

   Questions, bugs, contact Limin Fu at l2fu@ucsd.edu, or Weizhong Li at liwz@sdsc.edu
   For updated versions and information, please visit: http://cd-hit.org

   cd-hit web server is also available from http://cd-hit.org

   If you find cd-hit useful, please kindly cite:

   "Clustering of highly homologous sequences to reduce thesize of large protein database", Weizhong Li, Lukasz Jaroszewski & Adam Godzik. Bioinformatics, (2001) 17:282-283
   "Cd-hit: a fast program for clustering and comparing large sets of protein or nucleotide sequences", Weizhong Li & Adam Godzik. Bioinformatics, (2006) 22:1658-1659


Extract Part of a FASTA Sequences with Position by python script HERE

No comments:

Post a Comment

Have Problem ?? Drop a comments here!