This "optimal path" is based upon his or her genetics and past life "themes".
Then we lead whatever lives we lead. The difference is a fairly straight forward mathematical formula:
"where we are" minus "what our optimal path should be" equals
"our karma".