RandomAttack: Generate a random attack order

Description Usage Arguments Examples

View source: R/RandomAttack.R

Description

The most simple attack strategy. Targets either nodes or edges.

Usage

1
RandomAttack(g, Target = "Nodes", Number = 1, Name = "name")

Arguments

g

An igraph object representing a power-grid.

Target

The target of the attack. A string either "Nodes" or "Edges".

Number

The number of targets to generate. An integer the default is set to 1.

Name

The attribute name of the target

Examples

1
RandomAttack(g, Number = V(g))

JonnoB/PowerGridNetworking documentation built on Aug. 7, 2021, 3:04 a.m.