notepad++ text edit, fastq
1
0
Entering edit mode
2.2 years ago
Rob ▴ 170

strong textHi friends, I have a fastq file and I want to remove characters in the lines started with + and replace it with only "+" I tried in text editor but I couldn't as the number of characters are different in the lines with +.

Do you have any suggestion that helps me with this?

textedit
upload image

texteditor fastq notepad • 1.7k views
ADD COMMENT
8
Entering edit mode

enter image description here

ADD REPLY
3
Entering edit mode

Why would you want to do that ?

ADD REPLY
0
Entering edit mode

it is a question for my class and I have to be able to do it in notepad++ or excel

ADD REPLY
6
Entering edit mode

Then tell whoever is giving this class they they have no clue what they're doing when forcing students to manipulate omics data by hand. That is plain terrible. Opening fastq files in Excel, dear lord...

end_near

ADD REPLY
1
Entering edit mode

Lol yeah it really sucks and took lots of my time and effort anyways I have to do that for this class and will leave and forget it forever after this class

ADD REPLY
1
Entering edit mode

May I ask who is teaching this class and/or where it's being taught?

ADD REPLY
0
Entering edit mode
$ sed -r '3~4 s/^.*$/+/' test.fq
ADD REPLY
0
Entering edit mode

Aside from reasons of why this should not be done that have been mentioned, this could simply be a question about using a regular expression to make this change. NotePad++ is supposed to be able to use regular expression in search/replacements.

ADD REPLY
0
Entering edit mode

yes it is for using regex

ADD REPLY
0
Entering edit mode

yes it is for using regex

You left out that critical piece of information in your original question. Using NotePad++ was your idea or was that a requirement (seems unlikely but one never knows).

ADD REPLY
0
Entering edit mode

hi it is the requirement to use notepad++ for this part

ADD REPLY
3
Entering edit mode
2.2 years ago
ATpoint 82k

Never edit raw data by hand. This is both error-prone, irreproducible and for larger files not possible.

paste - - - -  < foo.fq | awk 'OFS="\n" {print $1, $2, "+", $4}'
ADD COMMENT

Login before adding your answer.

Traffic: 1625 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