How to extract sequences from a table?
Mostrar comentarios más antiguos
Hi All,
I am adapting the example by Mathworks, Sequence Classification using Deep Learning,, to work with my own problem.
I have the raw data coming in as a table, and I'm wondering is there a way to split this up into sequences, based on the values in one column, rather than an arbitrary number of rows down?
My table looks like this:

What I would like to do is to convert this to a cellarray, of various double arrays (from this picture above it will be x cells each with 2*y double arrays, however, the real table has a few more columns, so it's just an extension of this).
Many thanks,
James
4 comentarios
Dyuman Joshi
el 22 de Ag. de 2023
So you want to convert the table to a cell array where each cell element is data corresponding to a certain date?
James McBrearty
el 22 de Ag. de 2023
the cyclist
el 22 de Ag. de 2023
Can you upload the data, or a small representative sample? You can use the paper clip icon in the INSERT section of the toolbar.
James McBrearty
el 22 de Ag. de 2023
Respuesta aceptada
Más respuestas (1)
load FCTable
T=FCTable;
T.tradeDate=dateshift(FCTable.tradeDate,'start','day') ;
out = varfun(@(x) x, T,'Grouping', 'tradeDate','Output','cell')
1 comentario
James McBrearty
el 22 de Ag. de 2023
Categorías
Más información sobre Dates and Time 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!