View source: R/sfclust-methods.R
plot.sfclust | R Documentation |
sfclust
objectsThis function visualizes the estimated clusters from an sfclust
object. It can display:
(1) a map of regions colored by their assigned cluster,
(2) the functional shapes of the linear predictors for each cluster,
and (3) a traceplot of the log marginal likelihood.
A conditional legend is added if the number of clusters is less than 10.
## S3 method for class 'sfclust'
plot(
x,
sample = x$clust$id,
which = 1:3,
clusters = NULL,
sort = FALSE,
legend = FALSE,
...
)
x |
An |
sample |
Integer specifying the clustering sample number to summarize. Defaults to the last sample. |
which |
Integer vector indicating which plot to display. Options are: - 1: Map of regions colored by cluster assignment. - 2: Functional shapes of the linear predictors for each cluster. - 3: Traceplot of the log marginal likelihood. |
clusters |
Optional vector specifying which clusters to plot. If |
sort |
Logical value indicating whether clusters should be relabeled based on the number of elements. Default is |
legend |
Logical value indicating whether a legend should be included in the plot. Default is |
... |
Additional arguments passed to the underlying plotting functions. |
A plot displaying the selected subgraphs as specified by which
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.