MATLAB Answers

Steady State data finding

조회 수: 3(최근 30일)
Diego Dranuta
Diego Dranuta 2020년 11월 3일
편집: Asvin Kumar 2021년 3월 20일
Hi, I have a table with 5 columns
All=table(Time, PercentLoad, Enginecoolanttemp,DieselFuelRate,ExhaustGasTemp)
I need to find sections of that table so the output is one or multiple tambles where the difference in percent load is less than 5 over a time window of 30 seconds and of course keeping the other rows that come with those values together.
the output should be multiple tables like this
Time Percent Load EngineCoolantTemp DieselFuelRate ExhaustGasTemperature
100 20 80 65 554
101 20 80 65 560
102 21 81 65 570
103 22 81 65 550
104 22 81 66 568
105 21 82 66 547
106 21 81 66 563
107 21 81 66 540
108 22 81 68 536
109 23 80 67 521
110 23 79 67 511
111 23 79 69 508
112 23 78 70 498
113 23 79 74 478
114 25 80 73 467
115 25 80 74 456
116 24 80 73 447
117 24 80 73 439
118 23 81 73 428
119 24 81 72 419
120 24 81 72 400

답변(1개)

Asvin Kumar
Asvin Kumar 2021년 3월 18일
편집: Asvin Kumar 2021년 3월 20일
Seems like a job for diff and maybe cumsum on the diff depending on how you wish to handle the rolling window. Once you have those values, you could perform logical indexing to section out the rows where the load is within 5%.
find might also be useful to your task.

태그

Community Treasure Hunt

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

Start Hunting!

Translated by