I have an excel form, column a is time, column b is water level, column a has time corresponding to column b water level is blank, how to complete the water level of column b through python code...

You can use the fillna() method in the pandas library to complete the water level in column b, for example: df['b'] = df['b'].fillna(method='ffill') . You can also try to use other interpolation algorithms, such as the interpolate() function or the interp1d() function in the scipy library.

Guess you like

Origin blog.csdn.net/weixin_42588672/article/details/129577069