public void adjustTest()
{
double[,] data = (double[,])PrincipalComponentAnalysisTest.data.Clone();
PrincipalComponentAnalysis target = new PrincipalComponentAnalysis(data, AnalysisMethod.Standardize);
double[,] expected =
{
{ 0.87874523495823, 0.578856809114491 },
{ -1.66834240260186, -1.42942191638476 },
{ 0.496682089324217, 1.16952702249663 },
{ 0.114618943690204, 0.342588723761638 },
{ 1.64287152622626, 1.28766106517305 },
{ 0.624036471202221, 0.933258937143772 },
{ 0.241973325568208, -0.366215532296923 },
{ -1.03157049321184, -0.956885745679056 },
{ -0.394798583821814, -0.366215532296923 },
{ -0.904216111333831, -1.19315383103191 }
};
double[,] actual = target.Adjust(data, false);
Assert.IsTrue(expected.IsEqual(actual, 0.00001));
Assert.AreNotEqual(data, actual);
actual = target.Adjust(data, true);
Assert.IsTrue(expected.IsEqual(actual, 0.00001));
Assert.AreEqual(data, actual);
}