Often, during the initial setup of a project (or when revisiting one), there is a need to combine data matrices. It may be that new data has been collected that needs to be added to a calibration set. Or perhaps you are combining data sources for the same samples (process data, spectroscopic data, analytical tests, etc). In simple cases, you can always copy/paste the desired information, but if you have more than 2-3 matrices to combine, this can be a hassle. A nice, quick alternative is to use the Matrix Calculator function in The Unscrambler® X. This example will show combining sample sets.

1) Import all the data that you are interested in combining, and label your data matrices appropriately.
2) Check that number of variables/samples is consistent with each matrix. If appending new samples, then the number of variables must be the same and in the same order. If augmenting new data for existing samples, then the number of samples must be the same and in the same order. Note stay tuned for our upcoming sample alignment tool!
3) Select Tools – Matrix Calculator
4) Check the boxes next to each of the matrices you want to combine. And click on the Shaping tab.
Optionally, you may select Add category variable, which will add a new column with a category variable labeling which matrix the data came from. This is especially helpful when combining batches or different raw material types (such as in this example).
5) Click on Append to combine the data sample-wise. Note: clicking on Augment would combine the data variable-wise. Notice it is not currently available because the matrices do not have the same number of samples.
6) Click Close, and check your new combined matrix. If you clicked Add category variable, you will see that appended to the end of the matrix.