use of edu.cmu.tetrad.algcomparison.algorithm.multi.ImagesSemBic in project tetrad by cmu-phil.
the class TestImagesSimulation method test1.
public void test1() {
Parameters parameters = new Parameters();
parameters.set("numRuns", 1);
parameters.set("numMeasures", 100);
parameters.set("avgDegree", 8);
// parameters.set("maxDegree", 8);
// parameters.set("maxIndegree", 3);
// parameters.set("maxOutdegree", 3);
parameters.set("sampleSize", 500);
parameters.set("penaltyDiscount", 4);
// parameters.set("alpha", 0.001);
// parameters.set("maxDegree", 5);
// parameters.set("numCategoriesToDiscretize", 3);
parameters.set("intervalBetweenRecordings", 20);
parameters.set("varLow", 1.);
parameters.set("varHigh", 3.);
parameters.set("coefLow", .1);
parameters.set("coefHigh", 1);
parameters.set("coefSymmetric", true);
parameters.set("meanLow", -1);
parameters.set("meanHigh", 1);
// parameters.set("scaleFreeAlpha", .9);
// parameters.set("scaleFreeBeta", .05);
// parameters.set("scaleFreeDeltaIn", 3);
// parameters.set("scaleFreeDeltaOut", .1);
parameters.set("numRuns", 1);
parameters.set("randomSelectionSize", 3);
Statistics statistics = new Statistics();
// statistics.add(new ParameterColumn("numCategories"));
statistics.add(new AdjacencyPrecision());
statistics.add(new AdjacencyRecall());
statistics.add(new ArrowheadPrecision());
statistics.add(new ArrowheadRecall());
statistics.add(new ElapsedTime());
statistics.setWeight("AP", 1.0);
statistics.setWeight("AR", 0.5);
Algorithms algorithms = new Algorithms();
algorithms.add(new ImagesSemBic());
algorithms.add(new ImagesPcStableMax());
Simulations simulations = new Simulations();
simulations.add(new LinearFisherModel(new RandomForward()));
Comparison comparison = new Comparison();
comparison.setShowAlgorithmIndices(true);
comparison.setShowSimulationIndices(false);
comparison.setSortByUtility(false);
comparison.setShowUtilities(false);
comparison.setParallelized(true);
// comparison.setSaveGraphs(true);
comparison.setTabDelimitedTables(false);
comparison.compareFromSimulations("comparison", simulations, algorithms, statistics, parameters);
}
Aggregations