clusters_cor {ViSEAGO} | R Documentation

## Compute distance matrix between dendrograms partitions.

### Description

Build a distance or correlation matrix between partitions from dendrograms.

### Usage

    clusters_cor(clusters, method = "adjusted.rand")

    ## S4 method for signature 'list,character'
    clusters_cor(clusters,
      method = "adjusted.rand")

### Arguments

`clusters` | a `list` of `GO_clusters-class` objects, from `GOterms_heatmap` or `GOclusters_heatmap`, named as `character`.
`method` | available methods ("vi", "nmi", "split.join", "rand", or "adjusted.rand") from igraph package `compare` function.

### Value

a distance or a correlation matrix.

### References

Csardi G, Nepusz T: The igraph software package for complex network research, InterJournal, Complex Systems 1695. 2006. http://igraph.org.

### See Also

Other GO_clusters: `GO_clusters-class`, `GOclusters_heatmap`, `compare_clusters`, `show_heatmap`, `show_table`

### Examples

    ###################
    # load example object
    data(
        myGOs,
        package="ViSEAGO"
    )

    ## Not run:
    ###################
    # compute Semantic Similarity (SS)
    myGOs<-ViSEAGO::compute_SS_distances(
        myGOs,
        distance=c("Resnik","Lin","Rel","Jiang","Wang")
    )

    ##################
    # Resnik distance GO terms heatmap
    Resnik_clusters_wardD2<-ViSEAGO::GOterms_heatmap(
        myGOs,
        showIC=TRUE,
        showGOlabels=TRUE,
        GO.tree=list(
            tree=list(
                distance="Resnik",
                aggreg.method="ward.D2"
            ),
            cut=list(
                dynamic=list(
                    deepSplit=2,
                    minClusterSize =2
                )
            )
        ),
        samples.tree=NULL
    )

    ##################
    # Lin distance GO terms heatmap
    Lin_clusters_wardD2<-ViSEAGO::GOterms_heatmap(
        myGOs,
        showIC=TRUE,
        showGOlabels=TRUE,
        GO.tree=list(
            tree=list(
                distance="Lin",
                aggreg.method="ward.D2"
            ),
            cut=list(
                dynamic=list(
                    deepSplit=2,
                    minClusterSize =2
                )
            )
        ),
        samples.tree=NULL
    )

    ##################
    # Resnik distance GO terms heatmap
    Rel_clusters_wardD2<-ViSEAGO::GOterms_heatmap(
        myGOs,
        showIC=TRUE,
        showGOlabels=TRUE,
        GO.tree=list(
            tree=list(
                distance="Rel",
                aggreg.method="ward.D2"
            ),
            cut=list(
                dynamic=list(
                    deepSplit=2,
                    minClusterSize =2
                )
            )
        ),
        samples.tree=NULL
    )

    ##################
    # Resnik distance GO terms heatmap
    Jiang_clusters_wardD2<-ViSEAGO::GOterms_heatmap(
        myGOs,
        showIC=TRUE,
        showGOlabels=TRUE,
        GO.tree=list(
            tree=list(
                distance="Jiang",
                aggreg.method="ward.D2"
            ),
            cut=list(
                dynamic=list(
                    deepSplit=2,
                    minClusterSize =2
                )
            )
        ),
        samples.tree=NULL
    )

    ##################
    # Resnik distance GO terms heatmap
    Wang_clusters_wardD2<-ViSEAGO::GOterms_heatmap(
        myGOs,
        showIC=TRUE,
        showGOlabels=TRUE,
        GO.tree=list(
            tree=list(
                distance="Wang",
                aggreg.method="ward.D2"
            ),
            cut=list(
                dynamic=list(
                    deepSplit=2,
                    minClusterSize =2
                )
            )
        ),
        samples.tree=NULL
    )

    ## End(Not run)
    ###################
    # clusters to compare
    clusters<-list(
        Resnik="Resnik_clusters_wardD2",
        Lin="Lin_clusters_wardD2",
        Rel="Rel_clusters_wardD2",
        Jiang="Jiang_clusters_wardD2",
        Wang="Wang_clusters_wardD2"
    )

    ## Not run:
    ###################
    # global dendrogram clustering correlation
    clust_cor<-ViSEAGO::clusters_cor(
        clusters,
        method="adjusted.rand"
    )

    ## End(Not run)

[Package ViSEAGO version 1.0.0 Index]