- graph.us, graph
An igraph object, the graph for which the scan
statistics will be computed
- graph.them
An igraph object or NULL
, if not NULL
,
then the ‘them’ statistics is computed, i.e. the neighborhoods
calculated from graph.us
are evaluated on graph.them
.
- k
An integer scalar, the size of the local neighborhood for each
vertex. Should be non-negative.
- FUN
Character, a function name, or a function object itself, for
computing the local statistic in each neighborhood. If NULL
(the
default value), ecount
is used for unweighted graphs (if
weighted=FALSE
) and a function that computes the sum of edge
weights is used for weighted graphs (if weighted=TRUE
). This
argument is ignored if k
is zero.
- weighted
Logical scalar, TRUE if the edge weights should be used
for computation of the scan statistic. If TRUE, the graph should be
weighted. Note that this argument is ignored if FUN
is not
NULL
, "ecount"
and "sumweights"
.
- mode
Character scalar, the kind of neighborhoods to use for the
calculation. One of ‘out
’, ‘in
’,
‘all
’ or ‘total
’. This argument is ignored
for undirected graphs.
- neighborhoods
A list of neighborhoods, one for each vertex, or
NULL
. If it is not NULL
, then the function is evaluated on
the induced subgraphs specified by these neighborhoods.
In theory this could be useful if the same graph.us
graph is used
for multiple graph.them
arguments. Then the neighborhoods can be
calculated on graph.us
and used with multiple graphs. In
practice, this is currently slower than simply using graph.them
multiple times.
- ...
Arguments passed to FUN
, the function that computes
the local statistics.