Calculates the standard deviation of a variable among alters who both send to and receive from each ego.

egosd_sr(adj, var)

Arguments

adj

A square adjacency matrix.

var

A numeric vector of attribute values for each node.

Value

A numeric vector of egocentric standard deviations for each ego (NaN if no intersection).