Update – Upon further review, have determined that
Manipulate FASTQ is NOT a good tool choice for this particular task (for technical reasons around how the tool is designed). The tool does not interpret the entire string as a “word”. Instead, the function performs a direct translation, per character. This is useful in other situations, but not for this one.
How it works: the first character in the “from” string is translated to the first character in the “to” string; the second translated to the second; etc.
How this poorly impacts the result: All
1 characters will be translated to a
2 characters. Not just those following a
/ is replaced by another
Apologies, I should have tested this out first. Try
Sed as described in the other followup post. There is still likely a Python-version issue with the
Manipulate FASTQ tool at usegalaxy.eu … and it will be addressed … but even once that is done, don’t use this tool for
There are many ways/tools to “find/replace” data content, across datatypes, and the
Sed tool is one good choice. The “find” portion of the substitution function can be customized to fit any text characters, and the “replace” can also be fully customized. Other “find/replace” tools were created to make data substitution functions easier to perform – search the tool panel with the keyword “replace” to explore options if interested. Then test out your desired manipulation across the tools and see which produce the result you want – each act on data a little bit differently.
sed is worth learning how to use for many, even if just the simpler functions (like substations, aka
s/find/replace/. It is a common and stable command-line utility. The way it is used/interpreted in Galaxy is near exact to command-line usage. A web search will return many resources for
sed usage, examples, tutorials, tips&tricks, Q&A. There are also many “regular expression” syntax resources (including web forms where expressions can be “tested” as interpreted across several common utilities/scripting languages). Tool forms generally note which “type” of regular expression syntax is supported by the tool, along with basic syntax descriptions, examples, and link-outs to resources.
Yes, that would be a good tool choice. Incorrect, apologies! Everything below is WRONG for the original usage, but I’m leaving it posted since sometimes explaining what doesn’t work helps everyone to learn, discover and understand what will work, and importantly, why.
String translate the name/identifier. All reads in the file will be processed with the default “Match Reads” settings.