Eliminate Zero Spikes in Plot

A calculated curve (red, "brush contact force") is based on the smoothness of the original curves (blue, "brush position" and black, "shaft surface position"). Since oscillation in the original curves will lead to "Zero" values in the red curve the plot has areas including spikes down to 0. How can I eliminate those "zero" spikes in brush contact force data keeping the upper curve shape? Only the upper curve shape is needed for further analysis.

Respuestas (1)

Harald
Harald el 10 de Nov. de 2023

0 votos

Hi Jörg,
if possible, please provide example data so that we can try our suggestions. Two thoughts I would try:
  • rmoutliers
  • movmax, and then removing duplicates
Best wishes,
Harald

4 comentarios

Joerg Fricke-Schmidt
Joerg Fricke-Schmidt el 10 de Nov. de 2023
Hey Harald,
I attached the file with the curve data.
I'll check on rmoutliers and movmax.
Regrads,
Joerg
Harald
Harald el 10 de Nov. de 2023
Hi Jörg,
Fc.mat seems to just contain a logical array Fc_. It's not clear to me how this relates with the plot.
Best wishes,
Harald
Joerg Fricke-Schmidt
Joerg Fricke-Schmidt el 10 de Nov. de 2023
Oh sh..., sorry. Forgot to put the time in.
Now it should work.
Thanks a lot!
Harald
Harald el 13 de Nov. de 2023
Editada: Harald el 13 de Nov. de 2023
Hi Jörg,
in this case, it's actually sufficient to just remove the rows with 0 in the second column:
Fc_(Fc_(:,2) == 0, :) = [];
Best wishes,
Harald

Iniciar sesión para comentar.

Productos

Versión

R2023b

Etiquetas

Preguntada:

el 10 de Nov. de 2023

Editada:

el 13 de Nov. de 2023

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by