Skip to content
Martin Asser Hansen edited this page Oct 2, 2015 · 6 revisions

Biopiece: shuffle_records

Description

shuffle_records shuffles the records in the stream and output the records in random order.

Beware of memory usage since all records are loaded into memory for shuffling.

Usage

... | shuffle_records [options]

Options

[-?         | --help]               #  Print full usage description.
[-I <file!> | --stream_in=<file>!]  #  Read input from stream file  -  Default=STDIN
[-O <file>  | --stream_out=<file>]  #  Write output to stream file  -  Default=STDOUT
[-v         | --verbose]            #  Verbose output.

Examples

Consider the following FASTA entries in the file test.fna:

>test1
aaaa
>test2
tttt
>test3
cccc
>test4
gggg

To shuffle the records do:

read_fasta -i test.fna | shuffle_records | write_fasta -x

>test3
cccc
>test2
tttt
>test1
aaaa
>test4
gggg

See also

read_fasta

write_fasta

random_records

Author

Martin Asser Hansen - Copyright (C) - All rights reserved.

mail@maasha.dk

December 2010

License

GNU General Public License version 2

http://www.gnu.org/copyleft/gpl.html

Help

shuffle_records is part of the Biopieces framework.

http://www.biopieces.org

Clone this wiki locally