MyNixOS website logo
Description

Network Sparsification.

Network sparsification with a variety of novel and known network sparsification techniques. All network sparsification techniques reduce the number of edges, not the number of nodes. Network sparsification is sometimes referred to as network dimensionality reduction. This package is based on the work of Spielman, D., Srivastava, N. (2009)<arXiv:0803.0929>. Koutis I., Levin, A., Peng, R. (2013)<arXiv:1209.5821>. Toivonen, H., Mahler, S., Zhou, F. (2010)<doi:10.1007>. Foti, N., Hughes, J., Rockmore, D. (2011)<doi:10.1371>.

simplifyNet

Package for network sparsification.

Description

An R package for network sparsification with a variety of novel and known network sparsification techniques. All network sparsification reduce the number of edges, not the number of nodes. A network is usually a large, complex weighted graph obtained from real-world data. It is commonly stored as an adjacency matrix or edge list. Network sparsification is sometimes referred to as network dimensionality reduction.

Getting Started

Install and load devtools package:

install.packages("devtools")

Use install_github function to pull and install simplifyNet in your session:

install_github("kramera3/simplifyNet")

Prerequisites

The following packages are required:

igraph, sanic, Matrix, tidyr, methods, fields, stats, dplyr

Also set up the working directory:

setwd("<em>working directory</em>")

simplifyNet

simplifyNet is a R package for network sparsification. It contains a suite of different network sparsification algorithms to output a sparsified network.

Global Network Sparsification:

Global network sparsification. Uses a threshold cutoff to remove all edges below a certain edge weight or removes a certain proportion of lowest edge weight edges.

gns(E_List, remove.prop, cutoff)

Arguments

  • E_List: An edge list of the format |n1|n2|weight|)
  • remove.prop: The proportion of highest weighted edges to retain. A value between 0 and 1.
  • cutoff: Threshold value for edge weight thresholding.

LANS:

Local Adaptive Network Sparsification from the paper by Foti et al.

lans(Adj, remove.prop, output)

Arguments

  • Adj: Weighted adjacency matrix of the network.
  • remove.prop: Alpha value threshold to designate statistically "unimportant" edges by edge weight.
  • output: Designates if the output should be directed or undirected. Default is that the output is the same as the input based on adjacency matrix symmetry. If the default value is to be overridden, set as either "undirected" or "directed".

Sparsification by Edge Effective Resistances:

Sparsification by sampling edges proportional to their effective resistances as formulated by Spielman and Srivastava. This requires two discrete steps: (1) approximating the effective resistances for all edges, (2) sampling them according to the method devised by Spielman and Srivastava.

effR = EffR(E_List, epsilon, type="kts", tol)
EffRSparse(n, E_List, q, effR)
  1. EffR, effective resistances calculator.

    • E_List: Edge list formatted | n1 | n2 | weight |.

    • epsilon: Governs the relative fidelity of the approximation methods 'spl' and 'kts'. The smaller the value, the greater the fidelity of the approximation and the greater the space and time requirements. Default value is 0.1.

    • type: There are three methods.

      $1$ 'ext' which exactly calculates the effective resistances (WARNING! Not ideal for large graphs).

      $2$ 'spl' which approximates the effective resistances of the inputted graph using the original Spielman-Srivastava algorithm.

      $3$ 'kts' which approximates the effective resistances of the inputted graph using the implementation by Koutis et al. (ideal for large graphs where memory usage is a concern).

    • tol: Tolerance for the linear algebra (conjugate gradient) solver to find the effective resistances. Default value is 1e-10.

  2. EffRSparse, network sparsification through sampling effective resistances.

    • n: The number of nodes in the network.

    • E_List: Edge list formatted | n1 | n2 | weight |.

    • q: The numbers of samples taken. The fidelity to the original network increases as the number of samples increases, but decreases the sparseness.

    • effR: Effective resistances corresponding to each edge. Should be in the same order as "weight".

Authors

  • Dr. Andrew Kramer - Primary Author simplifyNet
  • Alexander Mercier - Package Maintainer
  • Shubhankar Tripathi - Contributor
  • Tomlin Pulliam - Contributor
  • John Drake - Contributor

Method Acknowledgements

License

  • GNU General Public License.
Metadata

Version

0.0.1

License

Unknown

Platforms (77)

    Darwin
    FreeBSD
    Genode
    GHCJS
    Linux
    MMIXware
    NetBSD
    none
    OpenBSD
    Redox
    Solaris
    WASI
    Windows
Show all
  • aarch64-darwin
  • aarch64-freebsd
  • aarch64-genode
  • aarch64-linux
  • aarch64-netbsd
  • aarch64-none
  • aarch64-windows
  • aarch64_be-none
  • arm-none
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv6l-none
  • armv7a-darwin
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • avr-none
  • i686-cygwin
  • i686-darwin
  • i686-freebsd
  • i686-genode
  • i686-linux
  • i686-netbsd
  • i686-none
  • i686-openbsd
  • i686-windows
  • javascript-ghcjs
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • m68k-none
  • microblaze-linux
  • microblaze-none
  • microblazeel-linux
  • microblazeel-none
  • mips-linux
  • mips-none
  • mips64-linux
  • mips64-none
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • mmix-mmixware
  • msp430-none
  • or1k-none
  • powerpc-netbsd
  • powerpc-none
  • powerpc64-linux
  • powerpc64le-linux
  • powerpcle-none
  • riscv32-linux
  • riscv32-netbsd
  • riscv32-none
  • riscv64-linux
  • riscv64-netbsd
  • riscv64-none
  • rx-none
  • s390-linux
  • s390-none
  • s390x-linux
  • s390x-none
  • vc4-none
  • wasm32-wasi
  • wasm64-wasi
  • x86_64-cygwin
  • x86_64-darwin
  • x86_64-freebsd
  • x86_64-genode
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-none
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris
  • x86_64-windows