I am using version 2021 R2.2

There's a point there: Using various matrices directly as a parameter range or as a plot axis is definitely not possible with the current way the matrix datasets storage works in Lumerical, you are right.

It may therefore be a good idea to remove the 'matrix' option from sweep parameters.

Also, while trying to find a solution for arbitrary-sized matrices Xi (matrix size chaging during the sweep, so size(Xi) != size(Xj) ), I thought about using a cell array instead of a normal array for parameter A. Like this, one could store the matrices Xi like A{i} = Xi.

However, I found out that cell array-type parameters in analysis groups do not work - one can not set any values to them, and the setup script won't find any parameter that is of type cell array.