Skip to content

Commit

Permalink
usage displays for .vcf.gz only
Browse files Browse the repository at this point in the history
- include note on main usage page about indexed/un-indexed VCF/BCF and streams
  • Loading branch information
mcshane committed Feb 21, 2014
1 parent 8d0afcf commit b9793a7
Show file tree
Hide file tree
Showing 12 changed files with 22 additions and 18 deletions.
6 changes: 5 additions & 1 deletion main.c
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,11 @@ static void usage(FILE *fp)
if ( cmds[i].func && cmds[i].help[0]!='-' ) fprintf(fp, "\t%-15s %s\n", cmds[i].alias, cmds[i].help);
i++;
}

fprintf(fp,"\n");
fprintf(fp,"Notes: Most commands accept VCF, bgzipped VCF and BCF with filetype detected\n");
fprintf(fp," automatically even when streaming from a pipe. Indexed VCF and BCF\n");
fprintf(fp," will work in all situations. Un-indexed VCF and BCF and streams will\n");
fprintf(fp," work in most, but not all situations.\n");
fprintf(fp,"\n");
}

Expand Down
2 changes: 1 addition & 1 deletion vcfannotate.c
Original file line number Diff line number Diff line change
Expand Up @@ -732,7 +732,7 @@ static void usage(args_t *args)
{
fprintf(stderr, "\n");
fprintf(stderr, "About: Annotate and edit VCF/BCF files.\n");
fprintf(stderr, "Usage: bcftools annotate [options] <in.bcf>|<in.vcf>|<in.vcf.gz>|-\n");
fprintf(stderr, "Usage: bcftools annotate [options] <in.vcf.gz>\n");
fprintf(stderr, "\n");
fprintf(stderr, "Options:\n");
fprintf(stderr, " -a, --annotations <file> VCF file or tabix-indexed file with annotations: CHR\\tPOS[\\tVALUE]+\n");
Expand Down
12 changes: 6 additions & 6 deletions vcfcall.c
Original file line number Diff line number Diff line change
Expand Up @@ -339,12 +339,12 @@ void parse_novel_rate(args_t *args, const char *str)
static void usage(args_t *args)
{
fprintf(stderr, "\n");
fprintf(stderr, "About: SNP/indel variant calling from VCF/BCF. To be used in conjunction with samtools mpileup.\n");
fprintf(stderr, " This command replaces the former \"bcftools view\" caller. Some of the original\n");
fprintf(stderr, " functionality has been temporarily lost in the process of transition to htslib,\n");
fprintf(stderr, " but will be added back on popular demand. The original calling model can be\n");
fprintf(stderr, " invoked with the -c option.\n");
fprintf(stderr, "Usage: bcftools call [options] <in.bcf>|<in.vcf>|<in.vcf.gz>|-\n");
fprintf(stderr, "About: SNP/indel variant calling from VCF/BCF. To be used in conjunction with samtools mpileup.\n");
fprintf(stderr, " This command replaces the former \"bcftools view\" caller. Some of the original\n");
fprintf(stderr, " functionality has been temporarily lost in the process of transition to htslib,\n");
fprintf(stderr, " but will be added back on popular demand. The original calling model can be\n");
fprintf(stderr, " invoked with the -c option.\n");
fprintf(stderr, "Usage: bcftools call [options] <in.vcf.gz>\n");
fprintf(stderr, "\n");
fprintf(stderr, "File format options:\n");
fprintf(stderr, " -O, --output-type <b|u|z|v> output type: 'b' compressed BCF; 'u' uncompressed BCF; 'z' compressed VCF; 'v' uncompressed VCF [v]\n");
Expand Down
2 changes: 1 addition & 1 deletion vcfconcat.c
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ static void usage(args_t *args)
fprintf(stderr, "About: Concatenate and/or combine overlapping VCF/BCF files split e.g. by chromosome\n");
fprintf(stderr, " or variant type. All source files must have the same sample columns appearing\n");
fprintf(stderr, " in the same order.\n");
fprintf(stderr, "Usage: bcftools concat [options] <A.bcf>|<A.vcf>|<A.vcf.gz> [<B.bcf>|<B.vcf>|<B.vcf.gz> ...]\n");
fprintf(stderr, "Usage: bcftools concat [options] <A.vcf.gz> [<B.vcf.gz> [...]]\n");
fprintf(stderr, "\n");
fprintf(stderr, "Options:\n");
fprintf(stderr, " -a, --allow-overlaps Combine overlapping files. Requires indexed files.\n");
Expand Down
2 changes: 1 addition & 1 deletion vcffilter.c
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,7 @@ static void usage(args_t *args)
{
fprintf(stderr, "\n");
fprintf(stderr, "About: Apply fixed-threshold filters.\n");
fprintf(stderr, "Usage: bcftools filter [options] <in.bcf>|<in.vcf>|<in.vcf.gz>|-\n");
fprintf(stderr, "Usage: bcftools filter [options] <in.vcf.gz>\n");
fprintf(stderr, "\n");
fprintf(stderr, "Options:\n");
fprintf(stderr, " -e, --exclude <expr> exclude sites for which the expression is true (e.g. '%%TYPE=\"snp\" && %%QUAL>=10 && (DP4[2]+DP4[3] > 2')\n");
Expand Down
4 changes: 2 additions & 2 deletions vcfgtcheck.c
Original file line number Diff line number Diff line change
Expand Up @@ -652,8 +652,8 @@ static char *init_prefix(char *prefix)
static void usage(void)
{
fprintf(stderr, "\n");
fprintf(stderr, "About: Check sample identity. With no -g VCF given, multi-sample cross-check is performed.\n");
fprintf(stderr, "Usage: bcftools gtcheck [options] [-g <genotypes.bcf>|<genotypes.vcf.gz>] <query.bcf>|<query.vcf.gz>\n");
fprintf(stderr, "About: Check sample identity. With no -g BCF given, multi-sample cross-check is performed.\n");
fprintf(stderr, "Usage: bcftools gtcheck [options] [-g <genotypes.vcf.gz>] <query.vcf.gz>\n");
fprintf(stderr, "\n");
fprintf(stderr, "Options:\n");
fprintf(stderr, " -a, --all-sites output comparison for all sites\n");
Expand Down
2 changes: 1 addition & 1 deletion vcfisec.c
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ static void usage(void)
{
fprintf(stderr, "\n");
fprintf(stderr, "About: Create intersections, unions and complements of VCF files.\n");
fprintf(stderr, "Usage: bcftools isec [options] <A.bcf>|<A.vcf.gz> <B.bcf>|<B.vcf.gz> [...]\n");
fprintf(stderr, "Usage: bcftools isec [options] <A.vcf.gz> <B.vcf.gz> [...]\n");
fprintf(stderr, "\n");
fprintf(stderr, "Options:\n");
fprintf(stderr, " -c, --collapse <string> treat as identical records with <snps|indels|both|all|some|none>, see man page for details [none]\n");
Expand Down
2 changes: 1 addition & 1 deletion vcfmerge.c
Original file line number Diff line number Diff line change
Expand Up @@ -1688,7 +1688,7 @@ static void usage(void)
fprintf(stderr, "\n");
fprintf(stderr, "About: Merge multiple VCF or BCF files to create one multi-sample file combining compatible records\n");
fprintf(stderr, " into one according to the -m option.\n");
fprintf(stderr, "Usage: bcftools merge [options] <A.bcf>|<A.vcf.gz> <B.bcf>|<B.vcf.gz> [...]\n");
fprintf(stderr, "Usage: bcftools merge [options] <A.vcf.gz> <B.vcf.gz> [...]\n");
fprintf(stderr, "\n");
fprintf(stderr, "Options:\n");
fprintf(stderr, " --use-header <file> use the provided header\n");
Expand Down
2 changes: 1 addition & 1 deletion vcfnorm.c
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,7 @@ static void usage(void)
{
fprintf(stderr, "\n");
fprintf(stderr, "About: Left-align and normalize indels.\n");
fprintf(stderr, "Usage: bcftools norm [options] -f <ref.fa> <in.bcf>|<in.vcf>|<in.vcf.gz>|-\n");
fprintf(stderr, "Usage: bcftools norm [options] -f <ref.fa> <in.vcf.gz>\n");
fprintf(stderr, "\n");
fprintf(stderr, "Options:\n");
fprintf(stderr, " -D, --remove-duplicates remove duplicate lines of the same type. [Todo: merge genotypes, don't just throw away.]\n");
Expand Down
2 changes: 1 addition & 1 deletion vcfquery.c
Original file line number Diff line number Diff line change
Expand Up @@ -643,7 +643,7 @@ static void usage(void)
{
fprintf(stderr, "\n");
fprintf(stderr, "About: Extracts fields from VCF/BCF file and prints them in user-defined format\n");
fprintf(stderr, "Usage: bcftools query [options] <A.bcf>|<A.vcf>|<A.vcf.gz>|- [<B.bcf>|<B.vcf.gz> ...]\n");
fprintf(stderr, "Usage: bcftools query [options] <A.vcf.gz> [<B.vcf.gz> [...]]\n");
fprintf(stderr, "\n");
fprintf(stderr, "Options:\n");
fprintf(stderr, " -a, --annots <list> alias for -f '%%CHROM\\t%%POS\\t%%MASK\\t%%REF\\t%%ALT\\t%%TYPE\\t' + tab-separated <list> of tags\n");
Expand Down
2 changes: 1 addition & 1 deletion vcfroh.c
Original file line number Diff line number Diff line change
Expand Up @@ -721,7 +721,7 @@ static void usage(args_t *args)
{
fprintf(stderr, "\n");
fprintf(stderr, "About: HMM model for detecting runs of autozygosity.\n");
fprintf(stderr, "Usage: bcftools roh [options] <in.bcf>|<in.vcf>|<in.vcf.gz>|-\n");
fprintf(stderr, "Usage: bcftools roh [options] <in.vcf.gz>\n");
fprintf(stderr, "\n");
fprintf(stderr, "General Options:\n");
fprintf(stderr, " -b, --biallelic-sites consider only bi-allelic sites\n");
Expand Down
2 changes: 1 addition & 1 deletion vcfview.c
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,7 @@ static void usage(args_t *args)
{
fprintf(stderr, "\n");
fprintf(stderr, "About: VCF/BCF conversion, view, subset and filter VCF/BCF files.\n");
fprintf(stderr, "Usage: bcftools view [options] <in.bcf>|<in.vcf>|<in.vcf.gz>|- [region1 [...]]\n");
fprintf(stderr, "Usage: bcftools view [options] <in.vcf.gz> [region1 [...]]\n");
fprintf(stderr, "\n");
fprintf(stderr, "Output options:\n");
fprintf(stderr, " -G, --drop-genotypes drop individual genotype information (after subsetting if -s option set)\n");
Expand Down

0 comments on commit b9793a7

Please sign in to comment.