The function adjusts a previous mds to take into account that samples were obtained under different conditions, e.g. technological or genetic. Pairwise adjustments are performed by identifying samples present in both conditions and using Procrustes. When there are more than two conditions, sequential pairwise adjustments are applied (in the order that maximizes the number of common samples in each pairwise adjustment). Object of class mds with a Multi-dimensional scaling analysis on a distance matrix, typically obtained by a previous call to mds. Object of class distGPS with the matrix used to create the Multidimensional Scaling object usually through a call to mds. Vector indicating the adjustment factor, i.e. the condition under which each sample has been obtained. Vector containing the sample identifier. sampleid should take the same value for samples obtained under different conditions, as this is used to detect the samples to be used for Procrustes adjustment. We implement the Procrustes adjustment as follows. First we identify common samples, i.e. those obtained both under conditions A and B. Second, we use Procrustes to estimate the shift, scale and rotation that best matches the position of the samples in B to those in A. If only 1 sample was obtained under both conditions, only the shift is estimated. Last, we apply the estimated shift, scale and rotation to all B samples. That is, the Procruses parameters are estimated using common samples only, which are then applied to all samples to perform the adjustment. Notice that the R square of the adjusted mds is typically improved after Procrustes adjustment, since distances between samples obtained under different conditions are set to NA and therefore MDS needs to approximate distances between less points. When several replicates are available for a given sampleid under the same condition (adjust), the average position of all replicates is used. Adjusted mds object. Have in mind that only original distances between samples obtained under the same condition should be conserved, as the adjusted distances manipulated by Procrustes no longer correlate with the distances between their points in the adjusted MDS. This site was developed by Ian Howson. I’m available to help with your software and statistics projects. All documentation is copyright its authors, I didn’t write any of that. Email me or if you have questions or problems. Source.