ShortestNodeDistance.intensitynet: Given two nodes, gives its shortest distance based on the...

View source: R/intensitynet.R

ShortestNodeDistance.intensitynetR Documentation

Given two nodes, gives its shortest distance based on the minimum amount of edges

Description

Calculates the shortest distance path between two nodes (based on the minimum amount of edges). The function also returns the total weight of the path, if the weight is not available, returns the number of edges.

Usage

## S3 method for class 'intensitynet'
ShortestNodeDistance(obj, node_id1, node_id2)

Arguments

obj

intensitynet object

node_id1

id of the starting node

node_id2

id of the end node

Value

distance of the path and the nodes of the path


intensitynet documentation built on April 11, 2023, 6:07 p.m.