{% set version = '1.7.2.1' %}

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

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/lava_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/lava/lava_{{ version }}.tar.gz
  sha256: d42b1f5c7e4e76718e4f014c44608295f82b5de0eb25ce8e9b35c40c7839ef2e

build:
  merge_build_host: True  # [win]
  # If this is a new build for the same version, increment the build number.
  number: 0
  # no skip
  noarch: generic

  # This is required to make R link correctly on Linux.
  rpaths:
    - lib/R/lib/
    - lib/

# Suggests: KernSmooth, Matrix, Rgraphviz, data.table, ellipse, fields, geepack, graph, knitr, bookdown, rmarkdown, igraph (>= 0.6), lavaSearch2, lme4, mets (>= 1.1), nlme, optimx, polycor, quantreg, rgl, R.rsp (>= 0.40), targeted (>= 0.2), testthat (>= 0.11), visNetwork, zoo
requirements:
  build:
    - {{ posix }}zip               # [win]

  host:
    - r-base
    - r-squarem
    - r-future.apply
    - r-numderiv
    - r-progressr
    - r-survival

  run:
    - r-base
    - r-squarem
    - r-future.apply
    - r-numderiv
    - r-progressr
    - r-survival

test:
  commands:
    # You can put additional test commands to be run here.
    - $R -e "library('lava')"           # [not win]
    - "\"%R%\" -e \"library('lava')\""  # [win]

  # You can also put a file called run_test.py, run_test.sh, or run_test.bat
  # in the recipe that will be run at test time.

  # requires:
    # Put any additional test requirements here.

about:
  home: https://kkholst.github.io/lava/
  license: GPL-3
  summary: A general implementation of Structural Equation Models with latent variables (MLE,
    2SLS, and composite likelihood estimators) with both continuous, censored, and ordinal
    outcomes (Holst and Budtz-Joergensen (2013) <doi:10.1007/s00180-012-0344-y>). Mixture
    latent variable models and non-linear latent variable models (Holst and Budtz-Joergensen
    (2020) <doi:10.1093/biostatistics/kxy082>). The package also provides methods for
    graph exploration (d-separation, back-door criterion), simulation of general non-linear
    latent variable models, and estimation of influence functions for a broad range
    of statistical models.
  license_family: GPL3
  license_file:
    - '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-3'

extra:
  recipe-maintainers:
    - mingwandroid

# The original CRAN metadata for this package was:

# Package: lava
# Type: Package
# Title: Latent Variable Models
# Version: 1.7.2.1
# Date: 2023-02-25
# Authors@R: c(person("Klaus K.", "Holst", email="klaus@holst.it", role=c("aut", "cre")), person("Brice", "Ozenne", role = "ctb"), person("Thomas", "Gerds", role = "ctb"))
# Author: Klaus K. Holst [aut, cre], Brice Ozenne [ctb], Thomas Gerds [ctb]
# Maintainer: Klaus K. Holst <klaus@holst.it>
# Description: A general implementation of Structural Equation Models with latent variables (MLE, 2SLS, and composite likelihood estimators) with both continuous, censored, and ordinal outcomes (Holst and Budtz-Joergensen (2013) <doi:10.1007/s00180-012-0344-y>). Mixture latent variable models and non-linear latent variable models (Holst and Budtz-Joergensen (2020) <doi:10.1093/biostatistics/kxy082>). The package also provides methods for graph exploration (d-separation, back-door criterion), simulation of general non-linear latent variable models, and estimation of influence functions for a broad range of statistical models.
# URL: https://kkholst.github.io/lava/
# BugReports: https://github.com/kkholst/lava/issues
# License: GPL-3
# LazyLoad: yes
# Depends: R (>= 3.0)
# Imports: future.apply, grDevices, graphics, methods, numDeriv, progressr, stats, survival, SQUAREM, utils
# Suggests: KernSmooth, Matrix, Rgraphviz, data.table, ellipse, fields, geepack, graph, knitr, bookdown, rmarkdown, igraph (>= 0.6), lavaSearch2, lme4, mets (>= 1.1), nlme, optimx, polycor, quantreg, rgl, R.rsp (>= 0.40), targeted (>= 0.2), testthat (>= 0.11), visNetwork, zoo
# VignetteBuilder: knitr
# ByteCompile: yes
# Encoding: UTF-8
# RoxygenNote: 7.2.3
# NeedsCompilation: no
# Packaged: 2023-02-25 19:47:09 UTC; Klaus.Holst
# Repository: CRAN
# Date/Publication: 2023-02-27 08:12:30 UTC

# See
# https://docs.conda.io/projects/conda-build for
# more information about meta.yaml
