Extract fasta sequences with ids in another file !
#Ids are in test.txt - one ids per line #sequences are in test.fa grep -w -A 2 -f test.txt test.fa --no-group-separator # seqtk seqtk subseq test.fa test.txt #faSomeRecods faSomeRecords in.fa listFile out.fa # seqkit seqkit grep -n -f list.txt sequences.fas > newfile2.fas882 days ago
bash script to extract sequence by ids !
Use a Perl one-liner, grep and seqtk subseq to extract the desired fasta sequences: # Create test...GAAAGAAGTATTACTAG Note that seqtk can be installed, for example, using conda.817 days ago
816 days ago
Install StringTie on ubuntu / Linux !
#StringTie is a software program to perform transcript assembly and quantification of RNAseq...ace/bin/stringtie-1.3.0.Linux_x86_64/stringtie ~/workspace/bin/stringtie # test installation ~/workspace/bin...816 days ago
805 days ago
Commands to Find and replace in file(s0) !
#Use SED sed -i 's/my/your/g' test.txt test2.txt test3.txt #Use FIND and SED find . -name *.txt -exec sed -i 's/my/your/g' {} \; #Use AWK awk '{sub(/{OLD_TERM}/,{NEW_TERM}); print}' {file} awk '{sub(/my/,your); print}' test.txt awk '{gsub(/i/,"a"); print}' test.txt763 days ago
Perl script for chi-squared test !
#!/usr/bin/perl # # chidi.pl # # A script to perform a chi-squared test of the dinucleotide frequenc...GT TA TC TG TT); # hashes for obersered and expected dinucl...increment the hash counter foreach my $i (0..length($seq)){...###### # Perform chi-squared test ############################...404 days ago