% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/motifs.R
\name{triad_census}
\alias{triad_census}
\title{Triad Census}
\usage{
triad_census(x)
}
\arguments{
\item{x}{A matrix, igraph object, or cograph_network}
}
\value{
Named vector of triad counts
}
\description{
Count the 16 types of triads in a directed network using MAN notation.
}
\details{
Triad census is defined only for directed networks. The input is always
treated as directed.

MAN notation describes triads by:
\itemize{
\item M: number of Mutual (reciprocal) edges
\item A: number of Asymmetric edges
\item N: number of Null (absent) edges
}

The 16 triad types are:
003, 012, 102, 021D, 021U, 021C, 111D, 111U,
030T, 030C, 201, 120D, 120U, 120C, 210, 300
}
\examples{
mat <- matrix(sample(0:1, 100, replace = TRUE), 10, 10)
diag(mat) <- 0
triad_census(mat)

}
\seealso{
\code{\link[=motifs]{motifs()}} for the unified API, \code{\link[=motif_census]{motif_census()}}

Other motifs: 
\code{\link{extract_motifs}()},
\code{\link{extract_triads}()},
\code{\link{get_edge_list}()},
\code{\link{motif_census}()},
\code{\link{motifs}()},
\code{\link{plot.cograph_motif_analysis}()},
\code{\link{plot.cograph_motifs}()},
\code{\link{subgraphs}()}
}
\concept{motifs}
\keyword{internal}
