Removing nodes
The next thing we will do is remove nodes that have made it into the network by mistake, usually as a result of false positives from pos_tagging
or NER
. You may see me refer to these nodes as “bad” nodes. I could as easily refer to them as “unwanted” nodes, but the point is that these are nodes that do not belong and should be removed. For simplicity, I call them bad nodes.
One reason to remove nodes is to clean a network so that it closely matches reality or the reality described in a piece of text. However, removing nodes can also be useful, for simulating an attack. We could, for instance, remove key characters from the Alice in Wonderland social network, to simulate what the outcome would be if the Queen of Hearts had gotten her wish of executing several characters. We will do that in this chapter.
Simulating an attack is also useful for bolstering defenses. If a node is a single point of failure and if its removal would be catastrophic...