How to find a specific sequence pattern in a fasta file?
I have to mine the following sequence pattern from a large fasta file namely gene.fasta (contains multiple fasta sequences) along with the flanking sequences of 5 bases at starting position and ending position,
I have a fasta file as follows,
gene.fasta
The expected output should be like this,
In order to mine the above mentioned pattern, I have used grep command but, I do not know how to specify only 3 bases for Z and also I could not specify N16 criteria in the grep command line. In addition to this, I do not know how to mine the 5 of the flanking bases along with the pattern. So kindly help me in this regard.
Thank you in advance.
Last edited by dineshkumarsrk; 11-29-2019 at 07:15 AM..
A developer of mine has this requirement - I couldn't tell her quickly how to do it with UNIX commands or a quick script so she's writing a quick program to do it - but that got my curiousity up and thought I'd ask here for advice.
In a text file, there are some records (about half of them)... (4 Replies)
Hi.. I have a seperate chromosome sequences and i wanted to parse some regions of chromosome based on start site and end site.. how can i achieve this?
For Example Chr 1 is in following format
I need regions from 2 - 10 should give me AATTCCAAA
and in a similar way 15- 25 should give... (8 Replies)
Hi all !
I have a fasta file that looks like that:
>Sequence1
RTYIPLCASQHKLCPITFLAVK
(it's just an example, obviously in reality I have several pairs of lines like that)
Using UNIX command(s), would it be possible to replace all the characters except the "C" of the second line only by... (7 Replies)
Hi
I have an alignment file (.fasta) with ~80 sequences. They look like this-
>JV101.contig00066(+):25302-42404|sequence_index=0|block_index=4|species=JV101|JV101_4_0
GAGGTTAATTATCGATAACGTTTAATTAAAGTGTTTAGGTGTCATAATTT
TAAATGACGATTTCTCATTACCATACACCTAAATTATCATCAATCTGAAT... (2 Replies)
I have fasta files with multiple sequences in each. I need to change the sequence name headers from:
>accD:_59176-60699
ATGGAAAAGTGGAGGATTTATTCGTTTCAGAAGGAGTTCGAACGCA
>atpA_(reverse_strand):_showing_revcomp_of_10525-12048
ATGGTAACCATTCAAGCCGACGAAATTAGTAATCTTATCCGGGAAC... (2 Replies)
I need assistance with following requirement, I am new to Unix.
I want to do the following task but stuck with file creation date(sysdate)
Following is the requirement
I need to create a script that will read the abc/xyz/klm folder and look for *.err files for that day’s date and then send an... (4 Replies)
Hi,
I want to match the sequence id (sub-string of line starting with '>' and extract the information upto next '>' line ). Please help .
input
> fefrwefrwef X900
AGAGGGAATTGG
AGGGGCCTGGAG
GGTTCTCTTC
> fefrwefrwef X932
AGAGGGAATTGG
AGGAGGTGGAG
GGTTCTCTTC
> fefrwefrwef X937... (2 Replies)
Hello,
I have 10 fasta files with sequenced reads information with read sizes from 15 - 35 . I have combined the reads and collapsed in to unique reads and filtered for sizes 18 - 26 bp long unique reads. Now i wanted to count each unique read appearance in all the fasta files and make a table... (5 Replies)
Hi
This is my first post and I'm just a beginner. So please be nice to me.
I have a couple of html files where a pattern beginning with "http://www.site.com" and ending with "/resource.dat" is present on every 241st line. How do I extract this to a new text file?
I have tried sed -n 241,241p... (13 Replies)
Discussion started by: dejavo
13 Replies
LEARN ABOUT DEBIAN
cdhit-2d
CD-HIT-2D(1) User Commands CD-HIT-2D(1)NAME
cdhit-2d - quickly group sequences in db1 or db2 format
SYNOPSIS
cdhit-2d [Options]
DESCRIPTION
====== CD-HIT version 4.6 (built on Apr 26 2012) ======
Options
-i input filename for db1 in fasta format, required
-i2 input filename for db2 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 5, see user's guide for choosing it
-l length of throw_away_sequences, default 10
-t tolerance for redundance, default 2
-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
-s2 length difference cutoff for db1, default 1.0 by default, seqs in db1 >= seqs in db2 in a same cluster if set to 0.9, seqs in db1
may just >= 90% seqs in db2
-S2 length difference cutoff, default 0 by default, seqs in db1 >= seqs in db2 in a same cluster if set to 60, seqs in db2 may 60aa
longer than seqs in db1
-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 tail-
ing 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 clus-
ter). 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
-bak write backup cluster file (1 or 0, default 0)
-h print this help
Questions, bugs, contact Weizhong Li at liwz@sdsc.edu
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
cd-hit-2d 4.6-2012-04-25 April 2012 CD-HIT-2D(1)