prune_leaves: A function that prunes leaves

Description Usage Arguments

View source: R/prune_leaves.R

Description

This function recursively removes leaves from a graph. A leave is a node with degree 1. The process stops if there is no leaves or the graph is a single node or empty graph.

Usage

1
prune_leaves(graph)

Arguments

graph

A graph that is stored in an adjacency matrix.


kelvinyangli/wrsgraph documentation built on Sept. 6, 2019, 10 a.m.