Last chance! 50% off unlimited learning
Sale ends in
An object of class "Clusters"
.
Generates n
2D points with k
(
If distribution="uniform"
, the points are uniformly generated in their square
supports where one square is the unit square (i.e., with vertices
If distribution="bvnormal"
, the points are generated from the bivariate normal distribution with means equal to the
centers of the above squares (i.e., for each cluster with mean=(j+(j-1)d-1/2,1/2) for
Notice that the clusters are more separated, i.e., generated data indicates more clear clusters as distribution="bvnormal"
,
the clustering gets stronger if the variance of each component,
rhor.clust(n, k, d, sd = 1/6, distribution = c("uniform", "bvnormal"))
A list
with the elements
The type of the clustering pattern
The number of clusters, k
, and the horizontal shift, d
, representing the level of clustering
(for both distribution types) and standard deviation, sd
, for the bivariate normal distribution only.
The output set of generated points from the k
clusters.
Description of the clustering pattern
The "main"
title for the plot of the point pattern
The number of generated points.
The possible ranges of the
A positive integer representing the number of points to be generated from all the clusters
A positive integer representing the number of clusters to be generated
Horizontal shift indicating the level of clustering in the data. Larger absolute values in either direction (i.e., positive or negative) would yield stronger clustering.
The standard deviation of the components of the bivariate normal distribution with default distribution="bvnormal"
.
The argument determining the distribution of each cluster. Takes on values "uniform"
and
"bvnormal"
whose centers are
Elvan Ceyhan
rdiag.clust
and rrot.clust
n<-100; #try also n<-50; or n<-1000;
d<-.5 #try also -.5,.75, 1
k<-3 #try also 5
#data generation
Xdat<-rhor.clust(n,k,d)
Xdat
summary(Xdat)
plot(Xdat,asp=1)
plot(Xdat)
#data generation (bvnormal)
n<-100; #try also n<-50; n<-1000;
d<-.1 #try also -.1, .75, 1
k<-3 #try also 5
Xdat<-rhor.clust(n,k,d,distr="bvnormal") #try also Xdat<-rhor.clust(n,k,d,sd=.15,distr="bvnormal")
Xdat
summary(Xdat)
plot(Xdat,asp=1)
plot(Xdat)
Run the code above in your browser using DataLab