{% set version = '2.2-2' %}

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

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

source:
  fn: relaimpo_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/relaimpo_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/relaimpo/relaimpo_{{ version }}.tar.gz
  sha256: f01b1aa296cb927dec086f1d8a07b64cf30e351b88a324a382da3fc1bd78b2e7

build:
  number: 0
  skip: true  # [win32]

  rpaths:
    - lib/R/lib/
    - lib/
requirements:
  build:
    - r-base
    - r-mass
    - r-boot
    - r-corpcor
    - r-mitools
    - r-survey

  run:
    - r-base
    - r-mass
    - r-boot
    - r-corpcor
    - r-mitools
    - r-survey

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

about:
  home: http://prof.beuth-hochschule.de/groemping/relaimpo/, http://prof.beuth-hochschule.de/groemping/
  license: GPL-2
  summary: relaimpo provides several metrics for assessing relative importance in linear models.
    These can be printed, plotted and bootstrapped. The recommended metric is lmg, which
    provides a decomposition of the model explained variance into non-negative contributions.
    There is a version of this package available that additionally provides a new and
    also recommended metric called pmvd. If you are a non-US user, you can download
    this extended version from Ulrike Groempings web site.
  license_family: GPL2

extra:
  recipe-maintainers:
    - johanneskoester
    - bgruening
    - daler
