measure_over: Helper functions for measuring over splits of networks

measure_overR Documentation

Helper functions for measuring over splits of networks

Description

  • over_membership() runs a function, e.g. a measure, over different group memberships

  • over_waves() runs a function, e.g. a measure, over waves of a panel network

  • over_time() runs a function, e.g. a measure, over time slices of a dynamic network

Usage

over_membership(
  .data,
  FUN,
  ...,
  membership,
  strategy = "sequential",
  verbose = FALSE
)

over_waves(
  .data,
  FUN,
  ...,
  attribute = "wave",
  strategy = "sequential",
  verbose = FALSE
)

over_time(
  .data,
  FUN,
  ...,
  attribute = "time",
  slice = NULL,
  strategy = "sequential",
  verbose = FALSE
)

Arguments

.data

A manynet-consistent network. See e.g. manynet::as_tidygraph() for more details.

FUN

A function to run over all splits.

...

Further arguments to be passed on to FUN.

membership

A categorical membership vector.

strategy

If {furrr} is installed, then multiple cores can be used to accelerate the function. By default "sequential", but if multiple cores available, then "multisession" or "multicore" may be useful. Generally this is useful only when times > 1000. See {furrr} for more.

verbose

Whether the function should report on its progress. By default FALSE. See {progressr} for more.

attribute

A string naming the attribute to be split upon.

slice

Optionally, a vector of specific slices. Otherwise all observed slices will be returned.


migraph documentation built on June 20, 2025, 5:08 p.m.