**clugenr** is an R implementation of the
*clugen* algorithm for generating multidimensional clusters with
arbitrary distributions. Each cluster is supported by a line segment,
the position, orientation and length of which guide where the respective
points are placed.

A stable version of the package is available on CRAN and can be installed with the following instruction:

`install.packages("clugenr")`

Alternatively, install the development version from GitHub with the following command (requires the devtools package):

`::install_github("clugen/clugenr") devtools`

All methods and functions are fully documented and can be queried
using the built-in help system. After installation, to access the man
pages, invoke the `clugenr`

help page as follows:

`help("clugenr")`

The complete online documentation is available here.

```
library(clugenr)
<- clugen(2, 5, 1000, c(1, -0.5), 0.5, c(4, 6), 6, 0.2, 0.5)
x plot(x$points, col = x$clusters, xlab = "x", ylab = "y", asp = 1)
```

```
library(clugenr)
library(rgl) # For 3D plots
<- clugen(3, 5, 2000, c(1, 0.5, -0.7), 0.5, c(15, 10, 20), 15, 3, 10)
x plot3d(x$points, col = x$clusters, xlab = "x", ylab = "y", zlab = "z", aspect = T)
```

- pyclugen, a Python
implementation of the
*clugen*algorithm. - CluGen.jl, an
Julia implementation of the
*clugen*algorithm. - MOCluGen, a
MATLAB/Octave implementation of the
*clugen*algorithm.

If you use this software, please cite the following reference:

- Fachada, N. & de Andrade, D. (2023). Generating multidimensional
clusters with support lines.
*Knowledge-Based Systems*, 277, 110836. https://doi.org/10.1016/j.knosys.2023.110836 (arXiv preprint)