add pruning functions