fixed i/j loop for PML in lav_objective.R