For large matrices do everything in your power to avoid using SUMPRODUCT given it is an "expensive" formula... use alternative methods (Pivots, helper cells etc...)
In this case I think you will find a basic SUMIF will suffice - you need just use an INDEX call to create the appropriate sum_range in the SUMIF.
B2:
=IF(ISNUMBER(MATCH(B$1,Data!$1:$1,0)),SUMIF(Data!$A:$A,$A2,INDEX(Data!$1:$65536,0,MATCH(B$1,Data!$1:$1,0))),0)
applied across matrix
The calculation time of the above will be virtually instantaneous... even so it would make sense to store the MATCH of month.year in a new row on Summary sheet (ie above below the month.year header).
This way you calculate the MATCH only once per column (the result is a constant for all rows) referring to the result cell in the subsequent matrix calcs as opposed to repeatedly calculating the match result.
(avoiding repetitive calculations is one of the golden rules when it comes to optimising performance of your model)
Bookmarks