Klasse MetricNMPrecision

java.lang.Object
org.deidentifier.arx.metric.Metric<org.deidentifier.arx.metric.InformationLossDefault>
org.deidentifier.arx.metric.MetricWeighted<org.deidentifier.arx.metric.InformationLossDefault>
org.deidentifier.arx.metric.MetricNMPrecision
Alle implementierten Schnittstellen:
Serializable

public class MetricNMPrecision extends MetricWeighted<org.deidentifier.arx.metric.InformationLossDefault>
This class provides an implementation of a weighted precision metric as proposed in:
Sweeney, L. (2002). Achieving k-anonymity privacy protection using generalization and suppression.
International Journal of Uncertainty Fuzziness and, 10(5), 2002.

This metric will respect attribute weights defined in the configuration.
Siehe auch:
  • Konstruktordetails

    • MetricNMPrecision

      protected MetricNMPrecision()
      Creates a new instance.
  • Methodendetails

    • createMaxInformationLoss

      public InformationLoss<?> createMaxInformationLoss()
      Beschreibung aus Klasse kopiert: Metric
      Returns an instance of the maximal value.
      Angegeben von:
      createMaxInformationLoss in Klasse Metric<org.deidentifier.arx.metric.InformationLossDefault>
      Gibt zurück:
    • createMinInformationLoss

      public InformationLoss<?> createMinInformationLoss()
      Beschreibung aus Klasse kopiert: Metric
      Returns an instance of the minimal value.
      Angegeben von:
      createMinInformationLoss in Klasse Metric<org.deidentifier.arx.metric.InformationLossDefault>
      Gibt zurück:
    • render

      public ElementData render(ARXConfiguration config)
      Beschreibung aus Klasse kopiert: Metric
      Renders the privacy model
      Angegeben von:
      render in Klasse Metric<org.deidentifier.arx.metric.InformationLossDefault>
      Gibt zurück:
    • toString

      public String toString()
      Beschreibung aus Klasse kopiert: Metric
      Returns the name of metric.
      Setzt außer Kraft:
      toString in Klasse Metric<org.deidentifier.arx.metric.InformationLossDefault>
      Gibt zurück:
    • getCells

      protected double getCells()
      Returns the number of cells.
      Gibt zurück:
    • getHeights

      protected int[] getHeights()
      Gibt zurück:
      the heights
    • getInformationLossInternal

      protected InformationLossWithBound<org.deidentifier.arx.metric.InformationLossDefault> getInformationLossInternal(Transformation<?> node, HashGroupify g)
      Beschreibung aus Klasse kopiert: Metric
      Evaluates the metric for the given node.
      Angegeben von:
      getInformationLossInternal in Klasse Metric<org.deidentifier.arx.metric.InformationLossDefault>
      Parameter:
      node - The node for which to compute the information loss
      g - The groupify operator of the previous check
      Gibt zurück:
      the double
    • getInformationLossInternal

      protected InformationLossWithBound<org.deidentifier.arx.metric.InformationLossDefault> getInformationLossInternal(Transformation<?> node, HashGroupifyEntry entry)
      Beschreibung aus Klasse kopiert: Metric
      Returns the information loss that would be induced by suppressing the given entry. The loss is not necessarily consistent with the loss that is computed by getInformationLoss(node, groupify) but is guaranteed to be comparable for different entries from the same groupify operator.
      Angegeben von:
      getInformationLossInternal in Klasse Metric<org.deidentifier.arx.metric.InformationLossDefault>
      Parameter:
      entry -
      Gibt zurück:
    • getLowerBoundInternal

      protected org.deidentifier.arx.metric.InformationLossDefault getLowerBoundInternal(Transformation<?> node)
      Beschreibung aus Klasse kopiert: Metric
      Returns a lower bound for the information loss for the given node. This can be used to expose the results of monotonic shares of a metric, which can significantly speed-up the anonymization process. If no such metric exists, simply return null.
      Setzt außer Kraft:
      getLowerBoundInternal in Klasse MetricWeighted<org.deidentifier.arx.metric.InformationLossDefault>
      Parameter:
      node -
      Gibt zurück:
    • getLowerBoundInternal

      protected org.deidentifier.arx.metric.InformationLossDefault getLowerBoundInternal(Transformation<?> node, HashGroupify groupify)
      Beschreibung aus Klasse kopiert: Metric
      Returns a lower bound for the information loss for the given node. This can be used to expose the results of monotonic shares of a metric, which can significantly speed-up the anonymization process. If no such metric exists, simply return null.

      This variant of the method allows computing a monotonic share based on a groupified data representation. IMPORTANT NOTE: The groups may not have been classified correctly when the method is called, i.e., HashGroupifyEntry.isNotOutlier may not be set correctly!
      Setzt außer Kraft:
      getLowerBoundInternal in Klasse MetricWeighted<org.deidentifier.arx.metric.InformationLossDefault>
      Parameter:
      node -
      groupify -
      Gibt zurück:
    • initializeInternal

      protected void initializeInternal(DataManager manager, DataDefinition definition, Data input, GeneralizationHierarchy[] hierarchies, ARXConfiguration config)
      Beschreibung aus Klasse kopiert: Metric
      Implement this to initialize the metric.
      Setzt außer Kraft:
      initializeInternal in Klasse MetricWeighted<org.deidentifier.arx.metric.InformationLossDefault>
      Parameter:
      manager -
      definition -
      input -
      hierarchies -
      config -