This is a test version of Biostars. For the public version, visit https://www.biostars.org.
convert fasta/qual into fastq files via terminal linux?

How can I convert two files one fasta and one which into a single fastq file via linux terminal, if anyone can help me I'll be grateful!

linux fastq

sorry you cut the sentence, it was a .fasta file and a .qual

.fasta

>IBN2P8H01DK86M length=51 xy=1355_0556 region=1 run=R_2013_06_25_14_33_34_
GGGTGATGATCGCAACATCAGCTGTACATCGAGTAGACGTTCTGCGAACAC

.qual

>IBN2P8H01DK86M length=51 xy=1355_0556 region=1 run=R_2013_06_25_14_33_34_
40 40 40 40 40 40 40 40 40 40 40 40 40 40 40 40 40 40 40 40 40 33 33 33 33 33 40 40 40 40 40 40 40 40 40 40 40 38 35 31 29 28 31 37 34 34 25 25 18 16 16

2 answers

See: http://qiime.org/scripts/convert_fastaqual_fastq.html

thank you, I will test it!

not tested, but it should be:

paste <(cat file1 | paste - - | sed 's/^/@/') \
          <(cat file2 | paste - - | cut -f2 )  |\
          awk -F '\t' '{printf("%s\n%s\n+\n%s\n",$1,$2,$3);}'

ah yes, sorry , that's too much for a saturday ! :-¨P

does not recognize -F command

Log in to answer this question.