@@ -111,6 +111,11 @@ def list_commands(self, ctx):
111
111
)
112
112
@handle_exception
113
113
def index (path , nrecords , stats ):
114
+ """
115
+ Query the number of records in a VCZ dataset. This subcommand only
116
+ implements the --nrecords and --stats options and does not build any
117
+ indexes.
118
+ """
114
119
if nrecords and stats :
115
120
raise click .UsageError ("Expected only one of --stats or --nrecords options" )
116
121
if nrecords :
@@ -156,6 +161,15 @@ def query(
156
161
include ,
157
162
exclude ,
158
163
):
164
+ """
165
+ Transform VCZ into user-defined formats with efficient subsetting and
166
+ filtering. Intended as a drop-in replacement for bcftools query, where we
167
+ replace the VCF file path with a VCZ dataset URL.
168
+
169
+ This is an early version an not feature complete: if you are missing a
170
+ particular piece of functionality please open and issue at
171
+ https://github.com/sgkit-dev/vcztools/issues
172
+ """
159
173
if list_samples :
160
174
# bcftools query -l ignores the --output option and always writes to stdout
161
175
output = sys .stdout
@@ -241,6 +255,15 @@ def view(
241
255
include ,
242
256
exclude ,
243
257
):
258
+ """
259
+ Convert VCZ dataset to VCF with efficient subsetting and filtering.
260
+ Intended as a drop-in replacement for bcftools view, where
261
+ we replace the VCF file path with a VCZ dataset URL.
262
+
263
+ This is an early version an not feature complete: if you are missing a
264
+ particular piece of functionality please open and issue at
265
+ https://github.com/sgkit-dev/vcztools/issues
266
+ """
244
267
suffix = output .name .split ("." )[- 1 ]
245
268
# Exclude suffixes which require bgzipped or BCF output:
246
269
# https://github.com/samtools/htslib/blob/329e7943b7ba3f0af15b0eaa00a367a1ac15bd83/vcf.c#L3815
0 commit comments