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

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/MCMCprecision_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/MCMCprecision/MCMCprecision_{{ version }}.tar.gz
  sha256: 90bb5874c3d39269ffab935517698b420faf73d8bbec81b78f38dccca7f8b4fe

build:
  merge_build_host: True  # [win]
  number: 0
  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-matrix
    - r-rcpp
    - r-rcpparmadillo
    - r-rcppeigen
    - r-rcppprogress
    - r-combinat
  run:
    - r-base
    - {{native}}gcc-libs         # [win]
    - r-matrix
    - r-rcpp
    - r-rcpparmadillo
    - r-rcppeigen
    - r-rcppprogress
    - r-combinat

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

about:
  home: https://github.com/danheck/MCMCprecision
  license: GPL-3
  summary: Estimates the precision of transdimensional Markov chain Monte Carlo  (MCMC) output,
    which is often used for Bayesian analysis of models with different  dimensionality
    (e.g., model selection). Transdimensional MCMC (e.g., reversible  jump MCMC) relies
    on sampling a discrete model-indicator variable to estimate  the posterior model
    probabilities. If only few switches occur between the models,  precision may be
    low and assessment based on the assumption of independent  samples misleading. Based
    on the observed transition matrix of the indicator  variable, the method of Heck,
    Overstall, Gronau, & Wagenmakers (2018,  Statistics & Computing) <doi:10.1007/s11222-018-9828-0>
    draws posterior samples  of the stationary distribution to (a) assess the uncertainty
    in the estimated  posterior model probabilities and (b) estimate the effective sample
    size of  the MCMC output.
  license_family: GPL3
  license_file: '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-3'

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

# Package: MCMCprecision
# Type: Package
# Title: Precision of Discrete Parameters in Transdimensional MCMC
# Version: 0.3.9
# Date: 2018-08-10
# Authors@R: c(person("Daniel W.","Heck", email="heck@uni-mannheim.de",role=c("aut","cre")))
# Author: Daniel W. Heck [aut, cre]
# Maintainer: Daniel W. Heck <heck@uni-mannheim.de>
# Description: Estimates the precision of transdimensional Markov chain Monte Carlo  (MCMC) output, which is often used for Bayesian analysis of models with different  dimensionality (e.g., model selection). Transdimensional MCMC (e.g., reversible  jump MCMC) relies on sampling a discrete model-indicator variable to estimate  the posterior model probabilities. If only few switches occur between the models,  precision may be low and assessment based on the assumption of independent  samples misleading. Based on the observed transition matrix of the indicator  variable, the method of Heck, Overstall, Gronau, & Wagenmakers (2018,  Statistics & Computing) <doi:10.1007/s11222-018-9828-0> draws posterior samples  of the stationary distribution to (a) assess the uncertainty in the estimated  posterior model probabilities and (b) estimate the effective sample size of  the MCMC output.
# License: GPL-3
# Encoding: UTF-8
# LazyData: true
# Depends: R (>= 3.0.0)
# Imports: Rcpp, parallel, utils, stats, Matrix, combinat
# Suggests: testthat, R.rsp
# LinkingTo: Rcpp, RcppArmadillo, RcppProgress, RcppEigen
# RoxygenNote: 6.1.0
# URL: https://github.com/danheck/MCMCprecision
# VignetteBuilder: R.rsp
# NeedsCompilation: yes
# Packaged: 2018-08-10 13:21:41 UTC; Daniel
# Repository: CRAN
# Date/Publication: 2018-08-10 13:40:03 UTC
