anvi-script-gen-genomes-file

Generate an external genomes or internal genomes file.

🔙 To the main page of anvi’o programs and artifacts.

Authors

Requires

contigs-db

Can use

profile-db collection

Provides

external-genomes internal-genomes

Usage

The primary purpose of this script is to reduce the amount of labor required to generate external-genomes or internal-genomes files anvi’o typically uses to learn about your bins and/or genomes.

Generating an external genomes file

If you provide an input directory and a name for the output file, then every contigs-db in that directory will get a line in the resulting external-genomes file:

anvi-script-gen-genomes-file --input-dir path/to/dir \
                             --output-file external_genomes.txt

Names for genomes in the resulting external genomes file will be set based on the project_name variable, and the contigs_db_path column will contain absolute paths.

You can learn the current project_name and/or change it for a given contigs-db using the program anvi-db-info. This variable is set by the program anvi-gen-contigs-database.

You can also instruct anvi-script-gen-genomes-file to include all subdirectories under a given directory path:

anvi-script-gen-genomes-file --input-dir path/to/dir \
                             --output-file external_genomes.txt \
                             --include-subdirs

Generating an internal genomes file

To get an internal-genomes file containing all bins from a collection, provide a profile-db, its corresponding contigs-db, and the collection name:

anvi-script-gen-genomes-file -c contigs-db \ -p profile-db \ -C collection \ --output-file internal-genomes.txt

The name of each internal genome will be the same as the bin name, and the path columns will contain absolute paths.

Edit this file to update this information.

Command line interface

The following is the list of parameters and their descriptions in the latest version of anvi-script-gen-genomes-file.

The code that generates this web page ensures that this information is the latest available in 9-dev (eunice). Which means, in some cases the information in this section (generated automatically) might be more comprehensive or up-to-date compared to the descriptions above (written by humans).


Command line usage

anvi-script-gen-genomes-file [-h] [--input-dir DIR_PATH] [--include-subdirs] [-c CONTIGS_DB] [-p PROFILE_DB] [-C COLLECTION_NAME] [-o FILE_PATH]

Parameters and their descriptions

EXTERNAL GENOMES Provide a directory, and anvi'o will provide an external genomes file containing all contigs dbs in that directory.
--input-dir DIR_PATH
Directory path for input files
--include-subdirs
Also search subdirectories for files.
INTERNAL GENOMES Provide a contigs db, profile db, and collection name and anvi'o will bestow upon you an internal genomes file for that collection.
-c, --contigs-db CONTIGS_DB
Anvi'o contigs database generated by 'anvi-gen-contigs-database'
-p, --profile-db PROFILE_DB
Anvi'o profile database
-C, --collection-name COLLECTION_NAME
Collection name.
OUTPUT Path for your internal or external genomes file
-o, --output-file FILE_PATH
File path to store results.

Additional Resources

Are you aware of resources that may help users better understand the utility of this program? Please feel free to edit this file on GitHub. If you are not sure how to do that, find the __resources__ tag in this file to see an example.