alan-turing-institute / network-comparison

An R package implementing the NetEMD and NetDis network comparison measures
MIT License
14 stars 3 forks source link

Make smoothing window a flag #119

Open martintoreilly opened 6 years ago

martintoreilly commented 6 years ago

Smoothing only works if the underlying x-axis is a unit "grid" and then the window must be 1. This should be a boolean flag where the name makes it clear what it is doing and the type of data it can be applied to.

e.g. something like diffuse_to_unit_interval?

andeElliott commented 6 years ago

I presume this is for NetEMD, if so then I agree :-)

martintoreilly commented 5 years ago

I think there are two potential robustness / generalisable approaches to smoothing.

andeElliott commented 5 years ago

One proposal that came up in a discussion with (@leospinaf) that is simple but gets us quite a way there.

Provide a discretisation function, that transforms the variables, prior to being send to the NetEmd comparison/optimisation with four implemented options (and let the user define others if needed)

1 Identity function (nothing is done) 2 Round to nearest integer. 3 Discretise to midpoint of user provided breaks.

  1. Simple histogram binning approach, i.e. make bins with breaks at minValue+x*(maxValue-minValue)/10 for x=0,...,10

We then leave the complex stuff for later work.

What do you think? @martintoreilly @leospinaf