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

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/support_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/support/support_{{ version }}.tar.gz
  sha256: 07b7ffd0dc5bdaeb266ee79bf6bf7616e880cfc14432b25512613841d38250f9

build:
  merge_build_host: True  # [win]
  number: 1
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - {{ compiler('c') }}              # [not win]
    - {{ compiler('m2w64_c') }}        # [win]
    - {{ compiler('cxx') }}            # [not win]
    - {{ compiler('m2w64_cxx') }}      # [win]
    - {{ posix }}filesystem        # [win]
    - {{ posix }}make
    - {{ posix }}sed               # [win]
    - {{ posix }}coreutils         # [win]
    - {{ posix }}zip               # [win]
  host:
    - r-base
    - r-bh
    - r-mhadaptive
    - r-rcpp >=0.12.4
    - r-rcpparmadillo
    - r-randtoolbox
  run:
    - r-base
    - {{ native }}gcc-libs         # [win]
    - r-bh
    - r-mhadaptive
    - r-rcpp >=0.12.4
    - r-rcpparmadillo
    - r-randtoolbox

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

about:
  home: https://CRAN.R-project.org/package=support
  license: GPL-2
  summary: The 'support' package provides the functions sp() and sp_seq() for computing the support
    points in Mak and Joseph (2018) <DOI:10.1214/17-AOS1629>. Support points can be
    used as a representative sample of a desired distribution, or a representative reduction
    of a big dataset (e.g., an "optimal" thinning of Markov-chain Monte Carlo sample
    chains). This work was supported by USARO grant W911NF-14-1-0024 and NSF DMS grant
    1712642.
  license_family: GPL2
  license_file:
    - '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-2'

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

# Package: support
# Type: Package
# Title: Support Points
# Version: 0.1.4
# Author: Simon Mak
# Maintainer: Simon Mak <sm769@duke.edu>
# Description: The 'support' package provides the functions sp() and sp_seq() for computing the support points in Mak and Joseph (2018) <DOI:10.1214/17-AOS1629>. Support points can be used as a representative sample of a desired distribution, or a representative reduction of a big dataset (e.g., an "optimal" thinning of Markov-chain Monte Carlo sample chains). This work was supported by USARO grant W911NF-14-1-0024 and NSF DMS grant 1712642.
# License: GPL (>= 2)
# LazyData: TRUE
# Imports: Rcpp (>= 0.12.4), randtoolbox, MHadaptive
# LinkingTo: Rcpp, RcppArmadillo, BH
# RoxygenNote: 6.1.1
# NeedsCompilation: yes
# Packaged: 2019-07-15 05:55:02 UTC; Simon
# Repository: CRAN
# Date/Publication: 2019-07-15 13:40:03 UTC
