how to replace duplicates with mean value in a table

2 visualizaciones (últimos 30 días)
Viktor G.
Viktor G. el 22 de Jun. de 2020
Comentada: Viktor G. el 22 de Jun. de 2020
I need to have a single value for every second of the time. Is there a simpler method of solving this without making for or while loops that compare every value to each other and then store the means in other table?
Sample =
10×4 table
Date Time Angle Speed
__________ __________ _____ _____
01/02/2014 '00:00:00' 62 3.6
01/02/2014 '00:00:00' 62 3.8
01/02/2014 '00:00:01' 60 4.1
01/02/2014 '00:00:01' 59 4.2
01/02/2014 '00:00:02' 58 4.3
01/02/2014 '00:00:02' 60 4.3
01/02/2014 '00:00:02' 64 4.3
01/02/2014 '00:00:03' 63 4.3
01/02/2014 '00:00:03' 61 4.3
01/02/2014 '00:00:04' 61 4.3
What i should get from this is
Sample =
10×4 table
Date Time Angle Speed
__________ __________ _____ _____
01/02/2014 '00:00:00' 62 3.7
01/02/2014 '00:00:01' 60 4.2
01/02/2014 '00:00:02' 61 4.3
01/02/2014 '00:00:03' 62 4.3
01/02/2014 '00:00:04' 61 4.3

Respuesta aceptada

madhan ravi
madhan ravi el 22 de Jun. de 2020

Más respuestas (0)

Categorías

Más información sobre Dates and Time en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by