numpy - Interpolate NaN values in a big matrix (not just a list) in python -
i'm searching simple method interpolate matrix 10% values nan. instance:
matrix = np.array([[ np.nan, np.nan, 2. , 3. , 4. ], [ np.nan, 6. , 7. , 8. , 9. ], [ 10. , 11. , 12. , 13., 14. ], [ 15. , 16. , 17. , 18., 19. ], [ np.nan, np.nan, 22. , 23., np.nan]])
i found solution uses griddata scipy.interpolate, solution take time. (my matrix have 50 columns , 200,000 rows , rate of nan values not higher 10%)
Comments
Post a Comment