This notebook demonstrates the usage of the TriDAMP package for three-way comparison of three groups of replicate datasets. The notebook is based on MathDAMP's 06-MathDAMP-MultipleGroups.nb notebook. The MathDAMP's functionality is used to normalize the datasets and calculate the F ratio (one-way ANOVA) result. The averages of the three groups's datasets are used for the three-way comparison. The F ratio result is then used to filter out statistically less significant differences from the three-way comparison.
The MathDAMP's functionality will not be commented in this notebook, for a brief explanation please refer to MathDAMP's 06-MathDAMP-MultipleGroups.nb notebook. For a more detailed explanation of TriDAMP's functionality, please refer to TriDAMP.nb (available upon request) and 01-TriDAMP-Basics.nb notebooks.
Step 1 : Loading the Data
First, the MathDAMP and TriDAMP packages have to be loaded. Please adjust the paths to package files according to their location on your system. Due to the size of the datasets and results the global variable $HistoryLength is set to 1 to save memory. 1.5 GB of physical memory may be necessary to execute this notebook.
Datasets acquired by capillary electrophoresis coupled to a time-of-flight mass spectrometer (CE-TOFMS) will be used for the demonstation in this notebook. The *.bdt datafiles were generated using a separate in house software from *.csv datafiles exported by the Analyst QS software. The original data were binned to a 0.02 m/z units resolution, baselines were subtracted from the individual electropherograms (as with the DAMPSubtractBaselines function with default options), noise was removed (as with the DAMPRemoveNoise function with default options), the data were binned to 1 m/z units resolution along the m/z axis and saved in a binary format as *.bdt datafiles.
Step 2 : Performing the Differential Analysis
The normalization of datasets is done in the same way as in MathDAMP's comparison of multiple groups of replicate datasets (please refer to the 06-MathDAMP-MultipleGroups.nb notebook for description).
Step 3 : Three-way comparison, Exploring the Results, Listing the Candidates
Averaged datasets are calculated for all three groups of replicate datasets which were normalized in the previous step. The averaged datasets are used to calculate the absolute, relative and absolute×relative three-way comparison results. The F ratio result dataset from previous section is used to filter the absolute×relative three-way comparison dataset (the F ratio threshold 3.9 corresponds to P=0.05 for comparisons of 3 groups of 5 replicates).
Below is a visualizations for one of the averaged datasets and a visualization of the filtered absolute×relative three-way comparison.
Overlaid electropherograms corresponding to the most significant differences from any result can be generated in descending order of significance. Below are electropherograms corresponding to the 24 most significant differences from the filtered absolute×relative three-way comparison result.
The candidate differences may be ranked according to the F ratio result as in MathDAMP's comparison of multiple groups of replicate datasets. As discussed in the 05-MathDAMP-TwoGroups.nb notebook, different results may have different strength and weaknesses, so it may prove beneficial to generate the lists of candidates according to multiple results to minimize the possibility of missing an important difference if it ranks lower in one particular result.