Skip to content
Version v0.6.0

Added two new commands, `call` and `segmetrics`, and a new `export` format, BED.

`segmetrics`::

- Calculates summary statistics of the residual bin-level log2 ratio estimates
  from the segment means, similar to the existing `metrics` command, but for
  each segment individually. Results are output in the same format as the CNVkit
  segmentation file (.cns), with the stat names and calculated values printed in
  the "gene" column.
- Supported stats: standard deviation, median absolute deviation, inter-quartile
  range, Tukey's biweight midvariance (as in `metrics`); also confidence
  interval, estimated by bootstrap; and prediction interval, estimated by the
  range between the 2.5-97.5 percentiles of bin-level log2 ratio values within
  the segment.
- Thanks to @mjafin for suggesting this feature (#28).

`call`::

- Given segmented log2 ratio estimates (.cns file), round the copy ratio
  estimates to integer values using either:

    - A list of threshold log2 values for each copy number state, or
    - Some algebra, given known tumor cell fraction and normal ploidy.

- The output is another .cns file, where the values in the `log2` column are
  still log2-transformed, but represent integers in log2 scale. E.g. neutral
  diploid state is represented as "0.0", not the integer 2. These output files
  are still compatible with the other CNVkit commands that accept .cns files.
- These calculations were previously done by the `export freebayes` command.
  That command is deprecated but still available in this release; it will be
  removed in the next release. The recommended approach is to instead run `call`
  first on each .cns file, and then `export bed` on all the adjusted .cns files
  to get an equivalent BED file compatible with FreeBayes `--cnv-map` option.

`export bed`:

- New format supporting the same features as `export freebayes` that were not
  moved into the `call` command (see above). The output BED file is still
  compatible with the FreeBayes `--cnv-map` option.
- New option `--show-neutral` to also output neutral-CN segments/regions, in
  addition to the CNV regions output by default.

Smaller changes:

- `gainloss`: Reduced the default log2 ratio threshold from .5 to .2
- `import-picard`: Use the un-normalized mean coverage instead of the normalized
  coverage of each target as the log2 coverage values in the output .cnn file.
  This matches the output of the `coverage` command; CNVkit normalizes coverages
  later in the pipeline.
- Some internal refactoring. Please report any bugs, real or perceived, on
  our GitHub issue tracker.