ExtractTimeSegment function

Time windows of HR record