Update a dataframe in pandas while iterating row by row Update a dataframe in pandas while iterating row by row python python