Refactored peer calcs. Needs troubleshooting. Separated helper fns.