Hi,
It's not just parameter 13.
For parameters 1-13 inclusive the array passed to AGGREGATE must be an actual worksheet range.
Only with parameters 14-19 can you use arrays which are array constants. This applies also to arrays resulting from some calculation performed on another array, e.g.:
=AGGREGATE(14,6,B1:B10/(A1:A10="A"),1)
which returns the largest value in B1:B10 whose corresponding entry in column A is "A".
Regards