networkDynamic for panel of larger networks

Open
#9 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
r
Domain
performance

Research direction

Start in R/utilities.R at the networkDynamic() loop referenced around line 628, then investigate whether tergm or sparse sociomatrix operations provide an existing approach for panel networks. Done means converting moderate-to-large panel networks substantially faster while preserving the resulting dynamicNetwork object; benchmark the reported two-network example.

Written by the indexing model from the issue text.

Description

In the current form, the function networkDynamic() is prohibitively slow for converting a list of panel networks of moderate to large size to a dynamicNetwork object (for example, a list of 2 networks with ~8000 nodes and 16k edges is taking on the order of hours). As far as I can tell, this issue stems from the implementation of a for-loop through all edges of the network here: https://github.com/statnet/networkDynamic/blob/66e66b91418ae6bf55b065d20f92115416cc448e/R/utilities.R#L628.

Based on the comments in the code, I am wondering if tergm or anything else already has a different way of taking on this task that is more efficient. I'm having trouble figuring out where exactly tergm does this, but I think it must do something similar when simulating. Perhaps an operation performed on a stack of sparse sociomatrices would be applicable here?

Dominant language
R
Stars
12
Forks
1
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from statnet/networkDynamic

All issues in statnet/networkDynamic

Similar issues

More R issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.