# Count occurrence after 3rd occurrence

Need to count occurrence of a missed punch after the 3rd occurrence as 0.5 points.
see table below

Cool virtual table problem. Give this a go:

``````Count After 3rd Occurrence =
VAR First3 =
FILTER( TOPN( 3, 'Data', 'Data'[Date], 1 ), 'Data'[COMMENT] = "Missed Punch" )
VAR DataMinusFirst3 =
EXCEPT( 'Data', First3 )
VAR Result =
CALCULATE( COUNTROWS( DataMinusFirst3 ), 'Data'[COMMENT] = "Missed Punch" )
RETURN
Result
``````

Total Points After 3rd Occurrence =

``````VAR First3 =
FILTER( TOPN( 3, 'Data', 'Data'[Date], 1 ), 'Data'[COMMENT] = "Missed Punch" )
VAR DataMinusFirst3 =
EXCEPT( 'Data', First3 )
VAR Result =
CALCULATE(
SUMX( DataMinusFirst3, [Total Points] ),
'Data'[COMMENT] = "Missed Punch"
)
RETURN
Result
``````

I hope this is helpful. Full solution file attached below.

P.S. When I first looked at this, I thought it was tallying boxing scoring (â€śmissed punchâ€ť), and then looked at the dates and thought â€śwow, this fight went on FOREVERâ€¦â€ť

1 Like

A post was split to a new topic: Second Variant of Scoring after the Third Occurrence