Description Usage Arguments Value See Also Examples
Plots the chart showing the clustering of the data. Depending on the dimensionality of the data passed to the afCEC function, it draws either 2D or 3D chart. The function doesn't work with the other dimensions.
Remarks:
The particular items are drawn cluster-by-cluster in the following order:
points
means
curves / surfaces
ellipses / ellipsoids of confidence
The functionality concerning drawing the means (see the draw_means
argument description for more details), ellipses / ellipsoids of confidence (see the draw_ellipsoids
argument description for more details) and curves / surfaces (see the draw_surfaces
argument description for more details) doesn't work if object x was retrieved after clustering the data with the active function family defined by the matrix of the active function components values on the data set. In that case, the above-mentioned arguments as well as the other ones related to them (for example meansSize2D
) are ignored and only data points are drawn on the chart. See afCEC.
Example: (due to the long running time it is not placed in the "Examples" section)
library(afCEC);
data(airplane);
result <- afCEC(airplane, 17);
plot(result);
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | ## S3 method for class 'afCEC'
plot(
x,
draw_points=TRUE,
draw_means=TRUE,
draw_ellipsoids=TRUE,
draw_surfaces=TRUE,
confidence=0.95,
grid_resolution=32,
pointsSize2D=1, pointsColor2D="cluster",
meansSize2D=2, meansColor2D="black",
ellipsesHeight2D=1, ellipsesColor2D="black",
surfacesHeight2D=1, surfacesColor2D="black",
XLabel2D="X", YLabel2D="Y",
pointsAlpha3D=1, pointsSize3D=0.01, pointsColor3D="cluster",
meansAlpha3D=0.5, meansSize3D=0.01, meansColor3D="black",
ellipsoidsAlpha3D=0.25, ellipsoidsColor3D="cluster",
surfacesAlpha3D=0.5, surfacesColor3D="cluster",
XLabel3D="X", YLabel3D="Y", ZLabel3D="Z",
...
)
|
x |
Object of class afCEC returned from the afCEC function. |
draw_points |
If the value is TRUE, the function draws the points belonging to the particular clusters. The default value is TRUE. |
draw_means |
If the value is TRUE, the function draws the means of the clusters as the big black dots / spheres. The default value is TRUE. |
draw_ellipsoids |
If the value is TRUE, the function draws the curved ellipses / ellipsoids of confidence of the particular clusters. The default value is TRUE. |
draw_surfaces |
If the value is TRUE, the function draws the curves / surfaces corresponding to the subspace spanned by the inactive axes of the particular clusters with respect to the curvilinear coordinate system determined by the active function with 0's in the means of the clusters. The default value is TRUE. |
confidence |
Determines the percentile of data belonging to the particular clusters, the corresponding ellipses / ellipsoids of confidence should contain. For example, if the value 0.5 is specified, then, for each cluster, it's ellipse / ellipsoid of confidence will contain 0.5 * 100 [%] of assigned points. The default value is 0.95. |
grid_resolution |
Determines the grid resolution using to approximate the curves / surfaces drawn in the plot function. The default value is 32. |
pointsSize2D |
Determines the size of the points (in pixels) drawn in the plot function. The argument is used only in the case of the 2D data. The default value is 1. |
pointsColor2D |
Determines the color of the points drawn in the plot function. It can hold the following values:
The argument is used only in the case of the 2D data. The default value is "cluster". |
meansSize2D |
Determines the size of the means (in pixels) drawn in the plot function. The argument is used only in the case of the 2D data. The default value is 2. |
meansColor2D |
Determines the color of the means drawn in the plot function. It can hold the following values:
The argument is used only in the case of the 2D data. The default value is "black". |
ellipsesHeight2D |
Determines the thickness of the ellipses (in pixels) drawn in the plot function. The argument is used only in the case of the 2D data. The default value is 1. |
ellipsesColor2D |
Determines the color of the ellipses drawn in the plot function. It can hold the following values:
The argument is used only in the case of the 2D data. The default value is "black". |
surfacesHeight2D |
Determines the thickness of the curves (in pixels) drawn in the plot function (see the |
surfacesColor2D |
Determines the color of the curves drawn in the plot function. It can hold the following values:
The argument is used only in the case of the 2D data. The default value is "black". |
XLabel2D |
Determines the label on the X axis of the chart drawn by the plot function. The argument is used only in the case of the 2D data. The default value is "X". |
YLabel2D |
Determines the label on the Y axis of the chart drawn by the plot function. The argument is used only in the case of the 2D data. The default value is "Y". |
pointsAlpha3D |
Determines the opacity of the points drawn in the plot function. The argument is used only in the case of the 3D data. The default value is 1. |
pointsSize3D |
Determines the size of the points drawn in the plot function. The size is expressed as the fraction of the maximal extent of the bounding box containing the whole of the data points. The argument is used only in the case of the 3D data. The default value is 0.01. |
pointsColor3D |
Determines the color of the points drawn in the plot function. It can hold the following values:
The argument is used only in the case of the 3D data. The default value is "cluster". |
meansAlpha3D |
Determines the opacity of the means drawn in the plot function. The argument is used only in the case of the 3D data. The default value is 0.5. |
meansSize3D |
Determines the size of the means drawn in the plot function. The size is expressed as the fraction of the maximal extent of the bounding box containing the whole of the data points. The argument is used only in the case of the 3D data. The default value is 0.01. |
meansColor3D |
Determines the color of the means drawn in the plot function. It can hold the following values:
The argument is used only in the case of the 3D data. The default value is "black". |
ellipsoidsAlpha3D |
Determines the opacity of the ellipsoids drawn in the plot function. The argument is used only in the case of the 3D data. The default value is 0.25. |
ellipsoidsColor3D |
Determines the color of the ellipsoids drawn in the plot function. It can hold the following values:
The argument is used only in the case of the 3D data. The default value is "cluster". |
surfacesAlpha3D |
Determines the opacity of the surfaces drawn in the plot function. The argument is used only in the case of the 3D data. The default value is 0.5. |
surfacesColor3D |
Determines the color of the surfaces drawn in the plot function. It can hold the following values:
The argument is used only in the case of the 3D data. The default value is "cluster". |
XLabel3D |
Determines the label on the X axis of the chart drawn by the plot function. The argument is used only in the case of the 3D data. The default value is "X". |
YLabel3D |
Determines the label on the Y axis of the chart drawn by the plot function. The argument is used only in the case of the 3D data. The default value is "Y". |
ZLabel3D |
Determines the label on the Y axis of the chart drawn by the plot function. The argument is used only in the case of the 3D data. The default value is "Z". |
... |
The remaining unused arguments of the built-in R plot function. |
None.
1 2 3 4 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.