Question: Combine multiple fasta files in galaxy?
0
gravatar for ando.kelli
2.9 years ago by
ando.kelli40
University of Tasmania
ando.kelli40 wrote:

Hi there,

I have a few hundred fasta files that I need to combine into a single fasta file. I thought it would be a relatively straight forward thing to do in Galaxy, but is proving to be a bit of a pain.

I was hoping to do this in Galaxy as I don't have command line experience.

Anyone know of a way to do this in Galaxy?

ADD COMMENTlink modified 2.6 years ago • written 2.9 years ago by ando.kelli40
1

You could do this in Windows (combining fasta files ) or linux/OS X (cat *.fa > new_dir/combined.fa).
If you want to do this in galaxy then perhaps this way: https://biostar.usegalaxy.org/p/8324/ (which may prove to be a huge pain).

ADD REPLYlink written 2.9 years ago by genomax67k
0
gravatar for Peter
2.8 years ago by
Peter5.8k
Scotland, UK
Peter5.8k wrote:

The Galaxy concatenate datasets tool ought to work nicely here (assuming you don't have any bad FASTA files missing a trailing new line character), essentially the command line tool cat wrapped for use within Galaxy.

ADD COMMENTlink written 2.8 years ago by Peter5.8k
0
gravatar for ando.kelli
2.6 years ago by
ando.kelli40
University of Tasmania
ando.kelli40 wrote:

Hi all,

I've ended up learning how to do all of my NGS analysis in a Linux environment (with some occasional text manipulation in Galaxy). For those who are daunted by the prospect like I was, I'd encourage you to get stuck in as it's made my life a lot easier (after an initial phase of constant Googling and confusion) :-) Github will be your best friend when looking for scripts/workflows.

To join the fasta files I did the following:

Make sure you are in the right directory (folder with your fasta files)

then:

cat *.fasta > combined.fasta

Using the * will combine all of the .fasta files in your current directory. If you don't want to join all of the files in the directory then be more selective like this:

cat fileone.fasta filetwo.fasta filethree.fasta > combined.fasta

you can also define where you want your output saved if you don't want it saved to the folder you're working in:

cat *.fasta > path/combined.fasta

Hope that helps :-)

Kel

ADD COMMENTlink modified 2.6 years ago • written 2.6 years ago by ando.kelli40
1

Good for you. Now that you have learned the power of command line there is no going back :-)

ADD REPLYlink written 2.6 years ago by genomax67k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 979 users visited in the last hour