{% set version = '0.1.5' %}

{% set posix = 'm2-' if win else '' %}
{% set native = 'm2w64-' if win else '' %}

package:
  name: r-cometexacttest
  version: {{ version|replace("-", "_") }}

source:
  fn: cometExactTest_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/cometExactTest_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/cometExactTest/cometExactTest_{{ version }}.tar.gz
  sha256: 377b6c10946eb08be3bc593fb494779646dc4fabbab27e466a3c34966a57292b

build:
  merge_build_host: True  # [win]
  number: 1003
  skip: true  # [win32]
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - posix                # [win]
    - {{ compiler('c') }}        # [unix]
    - {{ compiler('m2w64_c') }}  # [win]
  host:
    - r-base
    - r-dplyr

  run:
    - r-base
    - r-dplyr

test:
  commands:
    - $R -e "library('cometExactTest')"  # [not win]
    - "\"%R%\" -e \"library('cometExactTest')\""  # [win]

about:
  home: http://compbio.cs.brown.edu/projects/comet
  license: MIT
  summary: An algorithm for identifying combinations of mutually exclusive alterations in cancer
    genomes. CoMEt represents the mutations in a set M of k genes with a 2^k dimensional
    contingency table, and then computes the tail probability of observing T(M) exclusive
    alterations using an exact statistical test.
  license_family: MIT

extra:
  recipe-maintainers:
    - conda-forge/r
