Problem when using retime
Mostrar comentarios más antiguos
I have a timetable with temperature data from a meteorological station.
I use following function to pick out the daily maximum values and that works fine.
dailymax = retime(temptt, 'daily', 'max');
My problem is that in the column with the date and time (in the the resulting timetable), the time changes to 0:00 in every row. My date format is yyyy-mm-dd hh:mm.
Is there anyone who knows how to fix this?
Respuesta aceptada
Más respuestas (1)
Peter Perkins
el 31 de En. de 2019
0 votos
Sofie, if I understand correctly, you want to find, within each day, the maximum temperature, and the date/time at which that maximum occurred. Guillaume is correct that retime can't do that, unless you trick it. But there are easier ways.
As Guillaume says, splitapply is one way. Another is in my response to the same question a couple weeks ago.
Categorías
Más información sobre Tables en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!