added JP and JBP to plots, code cleanup