fit arbitrary functions to data in python