Package edu.pitt.dbmi.algo.resampling
Class GeneralResamplingTest
java.lang.Object
edu.pitt.dbmi.algo.resampling.GeneralResamplingTest
Created by mahdi on 1/16/17.
Updated: Chirayu Kong Wongchokprasitti, PhD on 9/13/2018
-
Constructor Summary
ConstructorsConstructorDescriptionGeneralResamplingTest(DataSet data, Algorithm algorithm, int numberResampling, double percentResamplingSize, boolean resamplingWithReplacement, int edgeEnsemble, boolean addOriginalDataset) Constructor.GeneralResamplingTest(List<DataSet> dataSets, MultiDataSetAlgorithm multiDataSetAlgorithm, int numberResampling, double percentResamplingSize, boolean resamplingWithReplacement, int edgeEnsemble, boolean addOriginalDataset) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionstatic int[][]getAdjConfusionMatrix(Graph truth, Graph estimate) Constructor.static int[][]getEdgeTypeConfusionMatrix(Graph truth, Graph estimate) Constructor.Returns the individual bootstrap result graphs.getOut()search()Runs the resampling test.voidsetExternalGraph(Graph externalGraph) Sets the initial graph.voidsetIndTestWrapper(IndependenceWrapper independenceWrapper) Sets the independence wrapper.voidsetKnowledge(Knowledge knowledge) Sets the background knowledge.voidsetOut(PrintStream out) Sets the output stream that output (except for log output) should be sent to.voidsetParameters(Parameters parameters) Sets the parameters.voidsetScoreWrapper(ScoreWrapper scoreWrapper) Sets the score wrapper.voidsetVerbose(boolean verbose) Sets whether verbose output should be produced.
-
Constructor Details
-
GeneralResamplingTest
public GeneralResamplingTest(DataSet data, Algorithm algorithm, int numberResampling, double percentResamplingSize, boolean resamplingWithReplacement, int edgeEnsemble, boolean addOriginalDataset) Constructor.- Parameters:
data- the data set.algorithm- the algorithm.numberResampling- the number of resampling.percentResamplingSize- the percent resampling size.resamplingWithReplacement- whether resampling with replacement.edgeEnsemble- the edge ensemble.addOriginalDataset- whether to add the original dataset.
-
GeneralResamplingTest
public GeneralResamplingTest(List<DataSet> dataSets, MultiDataSetAlgorithm multiDataSetAlgorithm, int numberResampling, double percentResamplingSize, boolean resamplingWithReplacement, int edgeEnsemble, boolean addOriginalDataset) Constructor.- Parameters:
dataSets- the data sets.multiDataSetAlgorithm- the multi data set algorithm.numberResampling- the number of resampling.percentResamplingSize- the percent resampling size.resamplingWithReplacement- whether resampling with replacement.edgeEnsemble- the edge ensemble.addOriginalDataset- whether to add the original dataset.
-
-
Method Details
-
getAdjConfusionMatrix
Constructor.- Parameters:
truth- the true graph.estimate- the estimated graph.
-
getEdgeTypeConfusionMatrix
Constructor.- Parameters:
truth- the true graph.estimate- the estimated graph.
-
setVerbose
public void setVerbose(boolean verbose) Sets whether verbose output should be produced.- Parameters:
verbose- whether verbose output should be produced.
-
getOut
- Returns:
- the output stream that output (except for log output) should be sent to.
-
setOut
Sets the output stream that output (except for log output) should be sent to. By default System.out.- Parameters:
out- the output stream that output (except for log output) should be sent to.
-
setParameters
Sets the parameters.- Parameters:
parameters- the parameters.
-
setKnowledge
Sets the background knowledge.- Parameters:
knowledge- the knowledge object, specifying forbidden and required edges.
-
setExternalGraph
Sets the initial graph. -
search
Runs the resampling test.- Returns:
- the graph.
-
setScoreWrapper
Sets the score wrapper.- Parameters:
scoreWrapper- the score wrapper.
-
setIndTestWrapper
Sets the independence wrapper.- Parameters:
independenceWrapper- the independence wrapper.
-
getGraphs
Returns the individual bootstrap result graphs.- Returns:
- A list of these Graphs.
-