MATLAB Answers

0

Using smoothdata on tallaray that contains time

Marcel Mabson さんによって質問されました 2018 年 3 月 21 日
最新アクティビティ Chris Turnes
さんによって 回答されました 2018 年 3 月 21 日
Good evening, I'm attempting to use the "smoothdata" on a tallarray that contains timestamps in one of the columns (I have a sensor that is modeling spacecraft reaction wheel speeds), but when I perform a gather to create the new maxtrix I get the following error. I have, also provided the input data format. I can work around the issue by just having the spacecraft time in seconds, but I wanted to reach out.
Oh, I also did not convert the tallarray to a timetable.
Thanks.
"Error using tall/smoothdata>iTabularWrapper (line 191) Table variables must be numeric. Learn more about errors encountered during GATHER.
Error in tall/smoothdata (line 50) y = iTabularWrapper(A,opts,fcn);"
SCTIME RWXSPEED RWYSPEED RWZSPEED
______________________ ________ ________ ________
18-043-00:36:48.018524 20.974 310 -40.924
18-043-00:36:49.018524 20.974 310 -40.924
18-043-00:36:50.018524 20.974 310 -40.924

  3 件のコメント

Walter Roberson
2018 年 3 月 21 日
smoothdata is documented to work on tables with numeric entries, and is documented to work on timetables, so it would seem to make sense to convert to a timetable.
Marcel Mabson 2018 年 3 月 21 日
I'm using a tall array, when I looked at 'A-Z functions that are supported under tall arrays' timetables are not supported when "smoothdata" is used. I'm using the smooth data function after I have created the tall array
Marcel Mabson 2018 年 3 月 21 日
Below is the gather command I use when I call "smoothdata" gather(smoothdata(tallarray,'sgolay',80))

サインイン to comment.

1 件の回答

Chris Turnes
回答者: Chris Turnes
2018 年 3 月 21 日

smoothdata does not support tall timetables, and similarly does not support the 'SamplePoints' Name-Value pair for tall inputs. If it's acceptable for your data to perform an 80-point Savitzky-Golay filter without using the timestamps (in other words, the filtering just goes by the index of the data value and does not use its associated timestamps for the regression), then you can use the 'DataVariables' Name-Value pair to select the numeric variables of your tall table and apply the approach that you've used so far.

  0 件のコメント

サインイン to comment.



Translated by