% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/member_core.R
\name{mark_core}
\alias{mark_core}
\alias{node_is_core}
\title{Marking nodes as core or periphery}
\usage{
node_is_core(.data, centrality = c("degree", "eigenvector"))
}
\arguments{
\item{.data}{A network object of class \code{mnet}, \code{igraph}, \code{tbl_graph}, \code{network}, or similar.
For more information on the standard coercion possible,
see \code{\link[manynet:as_tidygraph]{manynet::as_tidygraph()}}.}

\item{centrality}{Which centrality measure to use to identify cores and periphery.
By default this is "degree",
which relies on the heuristic that high degree nodes are more likely to be in the core.
An alternative is "eigenvector", which instead begins with high eigenvector nodes.
Other methods, such as a genetic algorithm, CONCOR, and Rombach-Porter,
can be added if there is interest.}
}
\value{
A \code{node_mark} logical vector the length of the nodes in the network,
giving either TRUE or FALSE for each node depending on
whether the condition is matched.
}
\description{
\code{node_is_core()} identifies whether nodes belong to the core of the
network, as opposed to the periphery.
}
\section{Core-periphery}{

This function is used to identify which nodes should belong to the core,
and which to the periphery.
It seeks to minimize the following quantity:
\deqn{Z(S_1) = \sum_{(i<j)\in S_1} \textbf{I}_{\{A_{ij}=0\}} + \sum_{(i<j)\notin S_1} \textbf{I}_{\{A_{ij}=1\}}}
where nodes \eqn{\{i,j,...,n\}} are ordered in descending degree,
\eqn{A} is the adjacency matrix,
and the indicator function is 1 if the predicate is true or 0 otherwise.
Note that minimising this quantity maximises density in the core block
and minimises density in the periphery block;
it ignores ties between these blocks.
}

\examples{
node_is_core(ison_adolescents)
ison_adolescents |> 
   mutate(corep = node_is_core())
}
\references{
\subsection{On core-periphery partitioning}{

Borgatti, Stephen P., & Everett, Martin G. 1999.
"Models of core /periphery structures".
\emph{Social Networks}, 21, 375–395.
\doi{10.1016/S0378-8733(99)00019-2}

Lip, Sean Z. W. 2011.
“A Fast Algorithm for the Discrete Core/Periphery Bipartitioning Problem.”
\doi{10.48550/arXiv.1102.5511}
}
}
\seealso{
Other core-periphery:
\code{\link{measure_core}},
\code{\link{member_core}}

Other marks:
\code{\link{mark_degree}},
\code{\link{mark_diff}},
\code{\link{mark_dyads}},
\code{\link{mark_nodes}},
\code{\link{mark_select_node}},
\code{\link{mark_select_tie}},
\code{\link{mark_ties}},
\code{\link{mark_triangles}}

Other nodal:
\code{\link{mark_degree}},
\code{\link{mark_diff}},
\code{\link{mark_nodes}},
\code{\link{mark_select_node}},
\code{\link{measure_assort_node}},
\code{\link{measure_broker_node}},
\code{\link{measure_brokerage}},
\code{\link{measure_central_between}},
\code{\link{measure_central_close}},
\code{\link{measure_central_degree}},
\code{\link{measure_central_eigen}},
\code{\link{measure_closure_node}},
\code{\link{measure_core}},
\code{\link{measure_diffusion_node}},
\code{\link{measure_diverse_node}},
\code{\link{member_brokerage}},
\code{\link{member_cliques}},
\code{\link{member_community}},
\code{\link{member_community_hier}},
\code{\link{member_community_non}},
\code{\link{member_components}},
\code{\link{member_core}},
\code{\link{member_diffusion}},
\code{\link{member_equivalence}},
\code{\link{motif_brokerage_node}},
\code{\link{motif_exposure}},
\code{\link{motif_node}},
\code{\link{motif_path}}
}
\concept{core-periphery}
\concept{marks}
\concept{nodal}
