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

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/dbscan_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/dbscan/dbscan_{{ version }}.tar.gz
  sha256: f3f5c8dad3c82bfdc075c957c937a38e87a9c795073ea9bf88ec2f056ea61be0

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

requirements:
  build:
    - {{ compiler('c') }}        # [not win]
    - {{ compiler('cxx') }}      # [not win]
    - {{native}}toolchain        # [win]
    - {{posix}}filesystem        # [win]
    - {{posix}}make
    - {{posix}}sed               # [win]
    - {{posix}}coreutils         # [win]
    - {{posix}}zip               # [win]
  host:
    - r-base
    - r-rcpp >=0.12.12
  run:
    - r-base
    - {{native}}gcc-libs         # [win]
    - r-rcpp >=0.12.12

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

about:
  home: https://CRAN.R-project.org/package=dbscan
  license: GPL (>= 2)
  summary: A fast reimplementation of several density-based algorithms of the DBSCAN family for
    spatial data. Includes the DBSCAN (density-based spatial clustering of applications
    with noise) and OPTICS (ordering points to identify the clustering structure) clustering
    algorithms HDBSCAN (hierarchical DBSCAN) and the LOF (local outlier factor) algorithm.
    The implementations use the kd-tree data structure (from library ANN) for faster
    k-nearest neighbor search. An R interface to fast kNN and fixed-radius NN search
    is also provided.
  license_family: GPL3
  license_file: '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-2'

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

# Package: dbscan
# Version: 1.1-3
# Date: 2018-11-12
# Title: Density Based Clustering of Applications with Noise (DBSCAN) and Related Algorithms
# Authors@R: c(person("Michael", "Hahsler", role = c("aut", "cre", "cph"), email = "mhahsler@lyle.smu.edu"), person("Matthew", "Piekenbrock", role = c("aut", "cph")), person("Sunil", "Arya", role = c("ctb", "cph")), person("David", "Mount", role = c("ctb", "cph")))
# Description: A fast reimplementation of several density-based algorithms of the DBSCAN family for spatial data. Includes the DBSCAN (density-based spatial clustering of applications with noise) and OPTICS (ordering points to identify the clustering structure) clustering algorithms HDBSCAN (hierarchical DBSCAN) and the LOF (local outlier factor) algorithm. The implementations use the kd-tree data structure (from library ANN) for faster k-nearest neighbor search. An R interface to fast kNN and fixed-radius NN search is also provided.
# Imports: Rcpp (>= 0.12.12), graphics, stats, methods
# LinkingTo: Rcpp
# Suggests: fpc, microbenchmark, testthat, dendextend, igraph, knitr, DMwR
# VignetteBuilder: knitr
# BugReports: https://github.com/mhahsler/dbscan
# License: GPL (>= 2)
# Copyright: ANN library is copyright by University of Maryland, Sunil Arya and David Mount. All other code is copyright by Michael Hahsler and Matthew Piekenbrock.
# SystemRequirements: C++11
# NeedsCompilation: yes
# Packaged: 2018-11-13 19:37:41 UTC; hahsler
# Author: Michael Hahsler [aut, cre, cph], Matthew Piekenbrock [aut, cph], Sunil Arya [ctb, cph], David Mount [ctb, cph]
# Maintainer: Michael Hahsler <mhahsler@lyle.smu.edu>
# Repository: CRAN
# Date/Publication: 2018-11-13 22:50:48 UTC
