Replace toScattered, toTotal, and similar functions with a single set type function. For the matrix, use a set.type for default behaviour and a expand function for additional behaviour.
Add unit tests for this
Check other functions that could be simplified or replaced with a get.set interface
Replace toScattered, toTotal, and similar functions with a single set type function. For the matrix, use a set.type for default behaviour and a expand function for additional behaviour.
Add unit tests for this
Check other functions that could be simplified or replaced with a get.set interface