Analogue for mean and spread of 2D lines

64 Views Asked by At

I have a set of 2D lines (contour lines from a collection of images), and would like to somehow represent them with an "average" and some measure of spread (se figure below). What could be a good way to achieve this? It will only be used for illustrative purposes, so the simpler the better.

2D lines summary

2

There are 2 best solutions below

1
On BEST ANSWER

I would try to forge parameterizations of each line, i.e. have a real variable $t$ such that $f(i,t)$ is the 2D function that provides the point of line number $i$ at time $t$. Then I would try to synchronize the parameterizations, i.e. try to minimize $|f(i, t) - f(j, t)|$ for all $t$ and for all $i \neq j$... that's the hard part. Then finally, I would say that the average line is parameterized by the average $f(t)$ of the $f(i,t)$. The spread would be at each $t$: $\sqrt{\frac{1}{n}\sum_{i=1}^n,|f(i,t)-f(t)|^2}$.

1
On

Consider (see below) a polar representation with a well chosen origin $O$ (depending on the "whirling" of the curves) with rays intersecting the curves in

$$r_1(\theta), r_2(\theta) ... r_n(\theta) \tag{1}$$

(no need to associate a curve to an index).

For a given value of $\theta$ :

  • Take the mean for the central curve (example : point $M$ below).

  • Take the standard deviation $\sigma$, or a multiple $a \sigma$, for limiting the gray area to line segment $S_{\theta}=[-a \sigma, a \sigma]$.

The continuity of values in (1) warrants that continuous curves will be generated in the process, as well for the locus of point $P$ as for the endpoints of the intervals $S_{\theta}$.

enter image description here