pyTempNets icon indicating copy to clipboard operation
pyTempNets copied to clipboard

Remove twopaths based on self loops

Open romanc opened this issue 10 years ago • 0 comments

The current implementation of extractTwoPaths will find two-paths based on self loops, ie 'a' -> 'b' -> 'b' or 'a' -> 'a' -> 'b' or 'a' -> 'a' -> 'a' will be marked as valid two-paths if there are appropriate self links.

To avoid this, just make sure s, v and d are jointly not equal when adding the two-path.This can be done with a one-line if statement right before https://github.com/IngoScholtes/pyTempNets/blob/master/pyTempNet/TemporalNetwork.py#L349

romanc avatar Oct 21 '15 16:10 romanc