clupoints_n_1 {clugenr}R Documentation

Create points from their projections on a cluster-supporting line

Description

Each point is placed on a hyperplane orthogonal to that line and centered at the point's projection, using the normal distribution (\(\mu=0\), \(\sigma=\) lat_disp ).

Usage

clupoints_n_1(projs, lat_disp, line_len, clu_dir, clu_ctr)

Arguments

projs

Point projections on the cluster-supporting line (\(p \times n\) matrix).

lat_disp

Standard deviation for the normal distribution, i.e., cluster lateral dispersion.

line_len

Length of cluster-supporting line (ignored).

clu_dir

Direction of the cluster-supporting line.

clu_ctr

Center position of the cluster-supporting line (ignored).

Details

This function's main intended use is by the main clugen function, generating the final points when the point_dist_fn parameter is set to "n-1".

Value

Generated points (\(p \times n\) matrix).

Note

This function is stochastic. For reproducibility set a PRNG seed with set.seed.

Examples

set.seed(123)
ctr <- c(0, 0)
dir <- c(1, 0)
pdist <- c(-0.5, -0.2, 0.1, 0.3)
proj <- points_on_line(ctr, dir, pdist)
clupoints_n_1(proj, 0.1, NA, dir, NA)

[Package clugenr version 1.0.3 Index]