I want to analyse the shape of data points from an image (see attached example), but since they include overhangs (non-continuous function = not to be numerically differentiated), I am not sure how to fit a curve to the shape. I want to do this in order to smooth out the curve, to increase the resolution along it, and to properly determine the maxima, minima and shape. A smoothing spline function is fitted to the example in the attachment. If necessary, I could live with losing the overhangs in the data due to the processing. Do you know how this kind of problem can be handled?

EDITS:

Thank you for the quick first answers. It seems some more explanaition is neccessary.

-> The data is not a timeseries, but a x,y shape I extracted from an micropscope-image via edge detection ond further modification (It's the edge of a biological cell). The points are indeed not well sorted; I did sort them by proximity, but there are still problems with a number of points.

-> By non-continuous I do not mean single points devided by a gap, but a series of points that cannot be described by one function (non-continuously differentiable). This is the reason why I ask for help in the first place. Otherwise fitting etc. would not pose a problem.

-> I would like to evaluate the hight, width and shape of the individual bumbs and their periodiciy.

In a separate answer message below, I attached two more files: An Image and a table with the (non-scaled) data points for the below curve.

It became clear that there is no reliable trick to handle this path as a 1D non-continuously differentiable function y(x). Instead it must be handled as a 2D function x(t),y(t) [t not beeing time but a randomly named variable for fitting purposes] and it needs to be sorted first, as suggested by later replies to this question.

-> The shape represents a cut through a cell, see publication at the bottom. As such there is a a "natural" up and down. To indicate that, I couloured the area under the curve green in the newly atached image.

-> All small features of the curve are artefacts of the edge detection and data handling procedure. They are not relevant and I would like to filter them out in the fitting process. I indicated this by the free-hand line in red that I inroduced to the attached image.

-> The "ovehangs" in the cell shape are the real problem here (but they are real in the biological samples). They prevent a proper 1D frequency analysis.

-> The points are not well sorted and not equaly spaced, since they simply represent pixles from an edge detection algorithm.

-> The cell shape and some other influences were already filtered out in the path discussed here.

Thank you!

Tobias

P.s.:

This work helped me with an aspect of my Masters Thesis where I acknowledged this forum as well as lead contributors in it. Much later the lines of code, modified over years, were used for this Publication in Nature of mine:

Article Disorder in convergent floral nanostructures enhances signal...

Full read access: https://rdcu.be/b4uKQ

The full code is available here:

https://github.com/MakerTobey/Data-extraction-from-crossection-TEM-images-of-biophotonic-structures

And data here:

https://osf.io/4tpp2/

More Tobias Wenzel's questions See All
Similar questions and discussions