sequence head change!
2
1
Entering edit mode
8.7 years ago
fufuyou ▴ 110

Hi, I have a lot of like as

HWI-ST1234:231:H2CNTADXY:1:1101:6127:2223       ACGAATCCGTGCGACGTGGGGCTGGAT     71
HWI-ST1234:231:H2CNTADXY:1:1101:19654:2083      CCTTTCTCCTCTTCGGCCTTCAAAGTTC    63.

I want to change to format like as

>HWI-ST1234:231:H2CNTADXY:1:1101:6127:2223 71
ACGAATCCGTGCGACGTGGGGCTGGAT
>HWI-ST1234:231:H2CNTADXY:1:1101:19654:2083 63
CCTTTCTCCTCTTCGGCCTTCAAAGTTC

Have some ways do like this for a lot of sequence? Thanks Fuyou

RNA-Seq • 1.8k views
ADD COMMENT
0
Entering edit mode

It's not immediately clear to me what has to be changed and what format your data is in...

ADD REPLY
4
Entering edit mode
8.7 years ago
awk '{printf(">%s %s\n%s\n",$1,$3,$2);}' in > out

and that's not much different from a previous answer for a question you asked: C: Add a sequence name!

ADD COMMENT
0
Entering edit mode

Thanks. It works.

ADD REPLY
1
Entering edit mode

so mark this question as answered, (icon on the left), as well as your previous question. Thanks.

ADD REPLY
1
Entering edit mode
8.7 years ago
rbagnall ★ 1.8k
awk -F " " '{print">"$1,$3,$2"\n>"$4,$6,$5}' in.fastq > out.fastq
ADD COMMENT
0
Entering edit mode

Hi rbagnall, Thanks, your results is HWI-ST1234:231:H2CNTADXY:1:1101:6127:2223 71 ACGAATCCGTGCGACGTGGGGCTGGAT , it is not like

HWI-ST1234:231:H2CNTADXY:1:1101:6127:2223 71 ACGAATCCGTGCGACGTGGGGCTGGAT.

ADD REPLY
0
Entering edit mode

Thanks Rbagnall. It works well. Fuyou

ADD REPLY

Login before adding your answer.

Traffic: 2565 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6