% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/sampling.R
\name{calcReclusterMatrix}
\alias{calcReclusterMatrix}
\title{Hierarchical graph clustering}
\usage{
calcReclusterMatrix(gg, mem, alg, CnMAX = 10, keepSplit = FALSE)
}
\arguments{
\item{gg}{graph to cluster}

\item{mem}{data.frame with previous level clustering results}

\item{alg}{algorithm to apply}

\item{CnMAX}{maximus size of the cluster in \code{mem} that will not be
processed}

\item{keepSplit}{logical, wether to keep previous membership in the output
matrix}
}
\value{
remembership matrix, that contains vertex ID membership and
result of reclustering
}
\description{
This function takes in a \code{gg} and initial vertex community membership
values \code{mem} as returned by \code{calcMembership}, and then performs a
reclustering of the graph given the clustering algorithm \code{alg} to those
clusters of size greater than \code{CnMAX}
}
\examples{
data(karate,package='igraphdata')
alg<-'louvain'
mem<-calcMembership(karate,alg = alg)
remem<-calcReclusterMatrix(karate,mem,alg,10)
}
