You can achieve it by using maxConditionsPerKey parameter.
Setting a number for this parameter will restrict the FKM dataview, particularly the trigger to display a defined number of rows, where the latest triggers would be displayed. By default, 1000 rows/lines of triggers is displayed per key.
FKM Plugin Basic Configuration - FAIL Key Word is "test"
FKM Plugin Advanced Configuration
Source file for monitoring contains 34 lines with the word ?test? in it
FKM Dataview with MaxConditionPerKey set to 5
FKM Dataview Without Setting MaxConditionPerKey