|
From: Mike D. <mik...@gm...> - 2022-03-29 21:01:14
|
Maybe try using the weights input for the below function? https://numpy.org/doc/stable/reference/generated/numpy.average.html On Tue, Mar 29, 2022 at 3:53 PM Michael (DataDriven portal) < mi...@da...> wrote: > Hi All, > > I have a 2D matrix with each cell that is backed by observations with > certain characteristics and shows weighted average performance values (see > below for an example). > > Some of the cells are backed by too few observations and therefore this 2D > surface is not smooth enough in those cells (see yellow cells below e.g.) > > What is the best algo for smoothing this surface taking into account the > number of observations (e.g. cells with more observations should we > weighted heavier). E.g. is there a Python weighted spline lib available or > something similar? > > [image: image.png] > > Thanks, > > Michael > _______________________________________________ > QuantLib-users mailing list > Qua...@li... > https://lists.sourceforge.net/lists/listinfo/quantlib-users > |