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

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/BayesLogit_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/BayesLogit/BayesLogit_{{ version }}.tar.gz
  sha256: 3a423f68339ed1bf25e21be53b1fd68452ed7807b17c36239fba759dc6fc6b70

build:
  merge_build_host: True  # [win]
  skip: true  # [r_base == "3.5.1"]
  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
  run:
    - r-base
    - {{ native }}gcc-libs         # [win]

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

about:
  home: https://github.com/jwindle/BayesLogit
  license: GPL-3.0-or-later
  summary: Tools for sampling from the PolyaGamma distribution based on Polson, Scott, and Windle
    (2013) <doi:10.1080/01621459.2013.829001>.  Useful for logistic regression.
  license_family: GPL3
  license_file:
    - '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-3'

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

# Package: BayesLogit
# Version: 2.1
# Date: 2019-09-25
# Title: PolyaGamma Sampling
# Authors@R: c( person("Nicholas G.", "Polson", role = c("aut", "cph")), person("James G.", "Scott", role = c("aut", "cph")), person("Jesse", "Windle", email = "jesse.windle@gmail.com", role = c("aut", "cre", "cph")), person("Jari", "Oksanen", role = c("ctb")), person("James", "Balamuta", role = c("ctb")))
# Maintainer: Jesse Windle <jesse.windle@gmail.com>
# Description: Tools for sampling from the PolyaGamma distribution based on Polson, Scott, and Windle (2013) <doi:10.1080/01621459.2013.829001>.  Useful for logistic regression.
# License: GPL (>= 3)
# Depends: R (>= 3.6.0)
# BugReports: https://github.com/jwindle/BayesLogit/issues
# URL: https://github.com/jwindle/BayesLogit
# NeedsCompilation: yes
# Packaged: 2019-09-25 15:12:48 UTC; jwindle
# Author: Nicholas G. Polson [aut, cph], James G. Scott [aut, cph], Jesse Windle [aut, cre, cph], Jari Oksanen [ctb], James Balamuta [ctb]
# Repository: CRAN
# Date/Publication: 2019-09-26 08:30:21 UTC
