@Test public void testLearn_doubleArrArr() { System.out.println("learn"); double[][] points = { {40.22360360457568, 18.504098418635056}, {-41.96153329423929, 15.679459081085987}, {-49.154520492544854, 23.057549478935496}, {10.598081220086218, 7.779540233953462}, {35.757866842749806, -4.0940414119709745}, {-45.05078778030483, 26.197239791961866}, {-55.284584971795624, -3.4691421950369614}, {-58.547722578180036, -0.581590856322055}, {-55.23402255948884, 11.41947137100053}, {-46.739993491044444, 17.75826916762321}, {-59.27724694557147, 2.5924406005262988}, {27.6737865285104, -18.86395047195548}, {31.583645719051308, -26.40457138526285}, {32.20027300792993, -19.14462360613023}, {30.93647170723012, -28.139903505514962}, {10.820417446883258, -25.981714242664278}, {40.61994472140328, 1.7893356291367033}, {36.893123121307056, 25.2011449401249}, {50.35435388043603, 23.460119648230112}, {30.31641225177879, -30.621625333828987}, {31.57301393922658, -18.462236251192287}, {33.48847606238201, -16.246616010675815}, {25.404563654492463, -7.368448245974307}, {34.198667011206695, -14.51548898530616}, {30.374194968862504, -32.03010239329132}, {31.799691626843952, -17.620915345075993}, {33.202462089583705, -26.623087076374446}, {28.74143110010598, -18.88136294206028}, {29.619321505441754, 16.53977754459522}, {33.21904729286558, -10.485990318581562}, {-68.03569731150479, -17.717332618032408}, {-66.8523610229811, -14.04860419250387}, {-69.0945497414166, -19.49039719928254}, {-63.412123082772155, -8.958925369982111}, {-60.125050342241366, 0.6420002976226844}, {-63.01224683586109, -7.474379597257728}, {-67.2871126283525, -15.967072181468266}, {-56.75383978958709, 3.8275706756047425}, {37.38667411461407, 1.48236982754225}, {42.09168775562593, 30.160624244349172}, {39.515694105763124, 20.31157656136279}, {34.40756902634357, 33.374967724530244}, {37.50347081823464, -1.1747328861102793}, {42.17288961345579, 16.841661303971275}, {17.7129501323806, 65.0200551147668}, {-6.945057439388253, 11.751691969153283}, {-7.62133456223296, 30.975890997191055} }; IsotonicMDS mds = IsotonicMDS.of(swiss); double sign = Math.signum(points[0][0] / mds.coordinates[0][0]); for (int i = 0; i < points.length; i++) { points[i][0] *= sign; } sign = Math.signum(points[0][1] / mds.coordinates[0][1]); for (int i = 0; i < points.length; i++) { points[i][1] *= sign; } assertEquals(0.023190, mds.stress, 1E-6); assertTrue(MathEx.equals(points, mds.coordinates, 1E-6)); }
public static IsotonicMDS of(double[][] proximity) { return of(proximity, new Properties()); }
IsotonicMDS { public static IsotonicMDS of(double[][] proximity) { return of(proximity, new Properties()); } }
IsotonicMDS { public static IsotonicMDS of(double[][] proximity) { return of(proximity, new Properties()); } IsotonicMDS(double stress, double[][] coordinates); }
IsotonicMDS { public static IsotonicMDS of(double[][] proximity) { return of(proximity, new Properties()); } IsotonicMDS(double stress, double[][] coordinates); static IsotonicMDS of(double[][] proximity); static IsotonicMDS of(double[][] proximity, int k); static IsotonicMDS of(double[][] proximity, Properties prop); static IsotonicMDS of(double[][] proximity, int k, double tol, int maxIter); static IsotonicMDS of(double[][] proximity, double[][] init, double tol, int maxIter); }
IsotonicMDS { public static IsotonicMDS of(double[][] proximity) { return of(proximity, new Properties()); } IsotonicMDS(double stress, double[][] coordinates); static IsotonicMDS of(double[][] proximity); static IsotonicMDS of(double[][] proximity, int k); static IsotonicMDS of(double[][] proximity, Properties prop); static IsotonicMDS of(double[][] proximity, int k, double tol, int maxIter); static IsotonicMDS of(double[][] proximity, double[][] init, double tol, int maxIter); final double stress; final double[][] coordinates; }