How can i convert a Time series data from table to cell array ?
    8 Ansichten (letzte 30 Tage)
  
       Ältere Kommentare anzeigen
    
    israt fatema
 am 17 Okt. 2019
  
    
    
    
    
    Beantwortet: Ganesh Regoti
    
 am 22 Okt. 2019
            I have a dataset as .csv like   
  Date                      Value 
  8/10/2019 11:50      1642 
  8/10/2019 11:55      1621 
I want to use the https://au.mathworks.com/help/deeplearning/examples/time-series-forecasting-using-deep-learning.html Time Series Forecasting Using Deep Learning (LSTM) with my data set. I tried to read the table first then convert the table to cell  C = table2cell(T) to match the example 
data = chickenpox_dataset;
data = [data{:}];
but it didn't match. As you can see, my dataset contains time series, with time steps corresponding to Date (and time) and values corresponding to some number. How to conver this table of 2 X 100 (0r more) as a cell array, where each element is a single time step and Reshape the data to be a row vector to match the exaple? Like row 1 contains the Date and time and row 2 contains value of each date and time, so that i can experiemnt the example?
2 Kommentare
  Ganesh Regoti
    
 am 21 Okt. 2019
				Hi Israt,
Could send a small snippet of data that would help in gaining more insight on the issue?
Akzeptierte Antwort
  Ganesh Regoti
    
 am 22 Okt. 2019
        Hi Stephen,
The model which you have specified is expecting an array of numeric data. I presume that you have converted the table data to cell format but not cell to array format. Here is the code snippet that could help you solve the issue
T = readtable('test.csv');
C = table2cell(T);
C = C';
Data = [C{2,:}];
Hope this helps!
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
				Mehr zu Logical finden Sie in Help Center und File Exchange
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


