# NOT RUN {
## Calculate gpv along a path in a sociomatrix
gpv(YangKnoke01, path = c(1,2,5), p = 1)
## The same calculation, with nonzero node costs
gpv(YangKnoke01, path = c(1,2,5), p = 1, node_costs = c(1,3,3,2,1))
## This path doesn't exist
gpv(YangKnoke01, path = c(1,2,4,5), p = 0)
# }
Run the code above in your browser using DataLab