File: coreness.Rd

package info (click to toggle)
r-cran-igraph 1.0.1-1%2Bdeb9u1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 18,232 kB
  • sloc: ansic: 173,538; cpp: 19,365; fortran: 4,550; yacc: 1,164; tcl: 931; lex: 484; makefile: 149; sh: 9
file content (53 lines) | stat: -rw-r--r-- 1,551 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/structural.properties.R
\name{coreness}
\alias{coreness}
\alias{graph.coreness}
\title{K-core decomposition of graphs}
\usage{
coreness(graph, mode = c("all", "out", "in"))
}
\arguments{
\item{graph}{The input graph, it can be directed or undirected}

\item{mode}{The type of the core in directed graphs. Character constant,
possible values: \code{in}: in-cores are computed, \code{out}: out-cores are
computed, \code{all}: the corresponding undirected graph is considered. This
argument is ignored for undirected graphs.}
}
\value{
Numeric vector of integer numbers giving the coreness of each
vertex.
}
\description{
The k-core of graph is a maximal subgraph in which each vertex has at least
degree k. The coreness of a vertex is k if it belongs to the k-core but not
to the (k+1)-core.
}
\details{
The k-core of a graph is the maximal subgraph in which every vertex has at
least degree k. The cores of a graph form layers: the (k+1)-core is always a
subgraph of the k-core.

This function calculates the coreness for each vertex.
}
\examples{
g <- make_ring(10)
g <- add_edges(g, c(1,2, 2,3, 1,3))
coreness(g) 		# small core triangle in a ring
}
\author{
Gabor Csardi \email{csardi.gabor@gmail.com}
}
\references{
Vladimir Batagelj, Matjaz Zaversnik: An O(m) Algorithm for Cores
Decomposition of Networks, 2002

Seidman S. B. (1983) Network structure and minimum degree, \emph{Social
Networks}, 5, 269--287.
}
\seealso{
\code{\link{degree}}
}
\keyword{graphs}