Fasta-uShuffle is a wrapper for uShuffle. ========================================= uShuffle is: uShuffle: A useful tool for shuffling biological sequences while preserving the k-let counts Minghui Jiang*, James Anderson, Joel Gillespie and Martin Mayne BMC Bioinformatics 2008, 9:192 doi:10.1186/1471-2105-9-192 http://www.biomedcentral.com/1471-2105/9/192 uShuffle software is available at: http://digital.cs.usu.edu/~mjiang/ushuffle/ Installation ============ download the code, then run "make": $ git clone git://github.com/agordon/fasta_ushuffle.git $ cd fasta_ushuffle $ make If needed, copy the executables to your bin directory: $ sudo cp fasta_ushuffle ushuffle /usr/local/bin Usage ===== $ ./fasta_ushuffle -h fasta_ushuffle: shuffles biological sequences while preserving the k-let counts. VERSION 0.2 Copyright (C) 2010 A. gordon (gordon@cshl.edu). Uses the uShuffle library code by: Minghui Jiang, James Anderson, Joel Gillespie, and Martin Mayne. Usage: fasta_ushuffle [-r N] [-h] [-o] [-n N] [-k N] [-s N] < INPUT.FA > OUTPUT.FA -h This help screen -o Print original (unshuffled) in output file. -k N specifies the let size -s N specifies the seed for random number generator. -n N For each input sequence, print N permutations (default is 1). Use this only for debugging. -r N Retry N times to find a new shuffle (Default is 10). After N retries, a warning is printed, and a non-shuffled sequence will be written. Nucleotide sequences in the input FASTA file must be in a single line. This is a valid input file: >dummy1 AGTAGTAGTAGTAGTAGTAGTAGTAGTAGTAGAGTG >dummy2 CTGAGAGTCACACATGATTTTACAACAACCATGAAG This is not a valid input file: >dummy1 AGTAGTAGTAGTAGTAGTAGTAGTAG TAGTAGAGTG >dummy2 CTGAGAGTCACACATGATTTTACAAC AACCATGAAG Use fasta_formatter (from the FASTX-Toolkit) to re-format a multiline fasta file. Example ======= $ ./fasta_ushuffle < test1.fa >hello ACGGGTTAAACCCGTTNN >world AGAAGTGAGTGTTGAGTAAGTACATTAGA LICENSE ======= uShuffle is distributed under the following license: /* Copyright (c) 2007 * Minghui Jiang, James Anderson, Joel Gillespie, and Martin Mayne. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * 1. Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright notice, * this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * 3. The names of its contributors may not be used to endorse or promote * products derived from this software without specific prior written * permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ The "fasta_ushuffle" wrapper code (fasta_ushuffle.c and fasta_ushuffle.h) are: Copyright (C) 2011,2012 by A. Gordon ( gordon at cshl dot edu ) licensed under the same license as uShuffle.