density: Functions to compute temporal density-related measures on...

Description Usage Arguments Details Value Note Author(s) References Examples

Description

These functions provide various network-level statistics giving information on the fraction of time edges are active in networkDynamic objects

Usage

1
2
tEdgeDensity(nd,mode=c('duration','event'),
              agg.unit=c('edge','dyad'),active.default=TRUE)

Arguments

nd

a networkDynamic object to evaluate density on

mode

option indicating if 'duration' of edge spells should be considered or only the 'event' count (for networks in which events have zero-durations)

agg.unit

option indicating how to calculate the possible observable time to be used as the denominator: 'edge' only counts existing edges 'dyad' counts all possible dyads.

active.default

logical, default TRUE. should edges without explicit timing information be considered active by default?

Details

The tEdgeDensity measure by default (mode='duration', agg.unit='edge') computes the total duration of activity of all the edges in the network and divides by the total amount of observable time for all the dyads between which edges are ever observed. Can be interpreted as the average fraction of observed edges active at any time. A value of 1 corresponds to a network in which all of the observed edges are always active (but the network still may be topologically sparse, having a low density)

The tEdgeDensity function with mode='event' computes the number of events (spells) occurring on each edge the network and divides it by the total amount of observable time per dyad ever observed to have an edge within the time bounds of the network. Can be interpreted as the fraction of existing ties toggling in a unit time step?

The agg.unit='dyad' measure computes the total duration (or count of events) of activity of all the edges in the network, and divides by the total amount of observable time for all the possible dyads (existing and non-existing edges). Value of 1 corresponds to a fully-connected network in which all edges are always active, value of 0 would be a network with no active edges. Can be interpreted as the average fraction of possible edges active at any time.

For networks with instantaneous spells, the event measures would be used in preference to the duration measures, as all of the events will have zero durations.

Note that all of these measures depend on having an accurate value for the temporal bounds of the network. If a net.obs.period exists, it will determine the range of observations. If it does not exist, the range will be the (non-Inf) range of earliest and latest events found on the network by get.change.times. If no non-Inf range exists (presumably because all ties are always active or always inactive), the range (0-1) will be used.

For sensible results on discrete networks, the measures are effectively making the assumption that the time increment is 1. TODO: read time increment from net.obs.period if it exits?

Networks with no edges or vertices will return 0, although they are technically undefined.

Behavior with multiplex ties? dyad measures could range above 1, edge measures will re-normalize.

Value

A numeric value representing the network-level measure of the density metric applied

Note

These are experimental functions, names and arguments still subject to change. Should these be collapsed to a single measure with multiple arguments?

Author(s)

skyebend

References

none yet

Examples

1
2
3
4
5
6
## Not run: 
require(networkDynamicData)
data(hospital_contact)
tEdgeDensity(hospital)

## End(Not run)

Example output

Loading required package: network
network: Classes for Relational Data
Version 1.13.0.1 created on 2015-08-31.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
                    Mark S. Handcock, University of California -- Los Angeles
                    David R. Hunter, Penn State University
                    Martina Morris, University of Washington
                    Skye Bender-deMoll, University of Washington
 For citation information, type citation("network").
 Type help("network-package") to get started.

Loading required package: networkDynamic

networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
                    Ayn Leslie-Cook, University of Washington
                    Pavel N. Krivitsky, University of Wollongong
                    Skye Bender-deMoll, University of Washington
                    with contributions from
                    Zack Almquist, University of California -- Irvine
                    David R. Hunter, Penn State University
                    Li Wang
                    Kirk Li, University of Washington
                    Steven M. Goodreau, University of Washington
                    Jeffrey Horner
                    Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").

Loading required package: networkDynamicData
[1] 0.001638299

tsna documentation built on Nov. 1, 2021, 5:06 p.m.