Update user_meta field from post_meta custom field

You cannot add something to a non-existent value; The first call would be: $total += (float)$roi; This is not possible, so Add/Initialize the variable $total = 0; before your $the_query loop.