Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

extract

Extract A Specific Cluster Solution From A Stride


Description

Extracts a specified cluster solution from an object of class ‘stride’. The desired solution is specified by the number of clusters.

Usage

## S3 method for class 'stride'
extract(stride,k)

Arguments

stride

an object of class ‘stride’ from function stride

k

the number of clusters desired

Details

A stride object consists of a list with a data.frame of cluster solutions for varying numbers of clusters. Extract simply selects one column of this data.frame (specified by number of clusters desired, not column number) and returns that solution as an object of class ‘clustering’.

Value

an object of class ‘clustering’.

Author(s)

David W. Roberts droberts@montana.edu

Examples

data(shoshveg)		                # get vegetation data
dis.bc <- dsvdis(shoshveg,'bray')   # calculate dissimilarity 
                                    #   matrix
avg.hcl <- hclust(dis.bc,'average') # average linkage cluster 
                                    #   analysis
avg.2.10 <- stride(2:10,avg.hcl)    # compute stride
res <- extract(avg.2.10,8)          # extract 8-cluster solution

optpart

Optimal Partitioning of Similarity Relations

v3.0-3
GPL (>= 2)
Authors
David W. Roberts <droberts@montana.edu>
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.