Klasse QualityModelRowOrientedSquaredError
java.lang.Object
org.deidentifier.arx.aggregates.quality.QualityModelRowOrientedSquaredError
Implementation of the Sum of Squared Errors introduced in the supplementary material to:
D. Sanchez, S. Martinez, and J. Domingo-Ferrer. Comment on unique in the shopping mall: On the reidentifiability of credit card metadata. Science, 351(6279):1274-1274, 2016.
D. Sanchez, S. Martinez, and J. Domingo-Ferrer. Comment on unique in the shopping mall: On the reidentifiability of credit card metadata. Science, 351(6279):1274-1274, 2016.
-
Konstruktorübersicht
KonstruktorenKonstruktorBeschreibungQualityModelRowOrientedSquaredError(WrappedBoolean interrupt, WrappedInteger progress, int totalWorkload, DataHandle input, DataHandle output, int suppressedInput, int suppressedOutput, Groupify<TupleWrapper> groupedInput, Groupify<TupleWrapper> groupedOutput, String[][][] hierarchies, QualityDomainShare[] shares, int[] indices, QualityConfiguration config) Creates a new instance -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungprotected voidChecks whether an interruption happened.evaluate()Evaluates the utility measureprotected double[][]getColumnsAsNumbers(DataHandle input, DataHandle output, String[][] hierarchy, int column) Returns a columns from the input and output dataset converted to numbersprotected QualityDomainShare[]Returns the domain sharesprotected Groupify<TupleWrapper> Returns grouped inputprotected Groupify<TupleWrapper> Returns grouped outputprotected String[][][]Returns the hierarchiesprotected int[]Returns relevant indicesprotected DataHandlegetInput()Returns inputprotected double[]getMinMax(double[] column) Returns minimum, maximum for the given columnprotected double[]getNumbersFromHierarchy(DataHandle handle, int column, String[][] hierarchy) Returns a numeric representation, relying on the hierarchyprotected double[]getNumbersFromNumericColumn(double[] inputAsNumbers, DataHandle output, int column) Parses numbers from a numeric output columnprotected double[]getNumbersFromNumericColumn(DataHandle input, int column) Parses numbers from a numeric input columnprotected double[]getNumbersFromNumericColumnAndHierarchy(DataHandle input, double[] inputAsNumbers, DataHandle output, int column, String[][] hierarchy) Uses numeric input and a hierarchy to construct rangesprotected DataHandleReturns outputprotected double[]getRangeFromNumericColumn(double[] inputNumbers, DataHandle output, int column) Tries to parse numbers from output when there is a numeric input columnprotected intReturns the number of records suppressed in inputprotected intReturns the number of records suppressed in outputprotected StringReturns the suppression stringprotected booleanisSuppressed(int column, String value) Returns whether a value is suppressedprotected booleanisSuppressed(DataHandle handle, int[] indices, int row) We assume that an entry is suppressed, if all values are equalprotected booleanisSuppressed(DataHandle handle, int row, int column) Returns whether a value is suppressedprotected doublelog2(double d) Log base-2protected voidOne step performedprotected voidsetSteps(int steps) Total number of stepsprotected voidAll steps performed
-
Konstruktordetails
-
Methodendetails
-
evaluate
Evaluates the utility measure- Gibt zurück:
-
checkInterrupt
protected void checkInterrupt()Checks whether an interruption happened. -
getColumnsAsNumbers
protected double[][] getColumnsAsNumbers(DataHandle input, DataHandle output, String[][] hierarchy, int column) Returns a columns from the input and output dataset converted to numbers- Parameter:
input-output-hierarchy-column-- Gibt zurück:
-
getGroupedInput
Returns grouped input -
getGroupedOutput
Returns grouped output -
getHierarchies
Returns the hierarchies -
getIndices
protected int[] getIndices()Returns relevant indices -
getInput
Returns input- Gibt zurück:
-
getMinMax
protected double[] getMinMax(double[] column) Returns minimum, maximum for the given column- Parameter:
column-- Gibt zurück:
-
getNumbersFromHierarchy
Returns a numeric representation, relying on the hierarchy- Parameter:
handle-column-hierarchy-- Gibt zurück:
-
getNumbersFromNumericColumn
Parses numbers from a numeric input column- Parameter:
input-column-- Gibt zurück:
-
getNumbersFromNumericColumn
protected double[] getNumbersFromNumericColumn(double[] inputAsNumbers, DataHandle output, int column) Parses numbers from a numeric output column- Parameter:
inputAsNumbers-output-column-- Gibt zurück:
-
getNumbersFromNumericColumnAndHierarchy
protected double[] getNumbersFromNumericColumnAndHierarchy(DataHandle input, double[] inputAsNumbers, DataHandle output, int column, String[][] hierarchy) Uses numeric input and a hierarchy to construct ranges- Parameter:
input-inputAsNumbers-output-column-hierarchy-- Gibt zurück:
-
getOutput
Returns output- Gibt zurück:
-
getRangeFromNumericColumn
Tries to parse numbers from output when there is a numeric input column- Parameter:
inputNumbers-output-column-- Gibt zurück:
-
getSuppressedRecordsInInput
protected int getSuppressedRecordsInInput()Returns the number of records suppressed in input- Gibt zurück:
-
getSuppressedRecordsInOutput
protected int getSuppressedRecordsInOutput()Returns the number of records suppressed in output- Gibt zurück:
-
getSuppressionString
Returns the suppression string- Gibt zurück:
-
isSuppressed
Returns whether a value is suppressed- Parameter:
handle-row-column-- Gibt zurück:
-
isSuppressed
We assume that an entry is suppressed, if all values are equal- Parameter:
entry-- Gibt zurück:
-
isSuppressed
Returns whether a value is suppressed- Parameter:
column-value-- Gibt zurück:
-
log2
protected double log2(double d) Log base-2- Parameter:
d-- Gibt zurück:
-
setStepPerformed
protected void setStepPerformed()One step performed -
setSteps
protected void setSteps(int steps) Total number of steps- Parameter:
steps-
-
setStepsDone
protected void setStepsDone()All steps performed
-