DATAVZRD

https://img.shields.io/github/issues-pr/snakemake/snakemake-wrappers/utils/datavzrd?label=version%20update%20pull%20requests

datavzrd allows to render tables by providing a configuration file. Configuration templates can be dynamically customized by utilizing the rendering integration. Any files specified in the configuration file have to be also specified as additional input files in the datavzrd rule.

URL: https://github.com/koesterlab/datavzrd

Example

This wrapper can be used in the following way:

rule datavzrd:
    input:
        config="resources/{sample}.datavzrd.yaml",
        # optional files required for rendering the given config
        table="data/A.tsv",
    output:
        report(
            directory("results/datavzrd-report/{sample}"),
            htmlindex="index.html",
            # see https://snakemake.readthedocs.io/en/stable/snakefiles/reporting.html
            # for additional options like caption, categories and labels
        ),
    log:
        "logs/datavzrd_report/{sample}.log",
    wrapper:
        "v1.19.2-18-gff15e44b/utils/datavzrd"

Note that input, output and log file paths can be chosen freely.

When running with

snakemake --use-conda

the software dependencies will be automatically deployed into an isolated environment before execution.

Software dependencies

  • datavzrd=2.9.0

Authors

  • Felix Mölder

Code

__author__ = "Johannes Köster"
__copyright__ = "Copyright 2017, Johannes Köster"
__email__ = "johannes.koester@protonmail.com"
__license__ = "MIT"

from snakemake.shell import shell

log = snakemake.log_fmt_shell(stdout=True, stderr=True)

shell("datavzrd {snakemake.input.config} --output {snakemake.output[0]} {log}")