Motifs in temporal networks

Temporal motifs code in SNAP

The code to count temporal network motifs is in the latest version of of SNAP. See the examples/temporalmotifs directory for sample code. Here is an example of how to use the code:

# Download SNAP
git clone https://github.com/snap-stanford/snap
# Build the code
cd snap/
make
# Run the temporal motifs example
cd examples/temporalmotifs/
./temporalmotifsmain -i:example-temporal-graph.txt -delta:300 -o:counts.txt
# See the output
cat counts.txt

The counts in the file counts.txt follow the counts matrix in the paper: