Info

此问题已关闭。 请重新打开它进行编辑或回答。

How to identify entries for a time frame?

1 次查看(过去 30 天)
I am trying to find the duplicate entries that occured within a 5 mintute duration. I have over 9,000 entries for over 1 year time frame. Here is a sample of the data:
Start Date Citrcuit Cause Location Bay
1) 2/6/2019 09:01:00 AC122 OOO AC 2
2) 12/26/2018 11:02:00 AC122 PPP AC 2
3) 9/29/2018 13:14:00 AC123 CCC AC 2
4) 9/29/2018 13:13:00 AC124 CCC AC 2
Result that i am looking for is that Maltab would identfiy the location of AC had 2 entries within a 5 minute window.

回答(1 个)

Peter Perkins
Peter Perkins 2019-5-24
The data in your example are VERY sparse, and it's hard to know if that's typical or not.
One very simple way to do what you want is to create a timetable, and retime it to a regular 5 minute time steps using @numel as the aggregation function. But there are 105120 5 minute intervals in one year, and if your data are typicalp, you'd be making a result that mostly had zeros in it.

标签

Community Treasure Hunt

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

Start Hunting!

Translated by