当前位置: 首页>>代码示例>>Java>>正文


Java PopulationUniquenessModel.DANKAR属性代码示例

本文整理汇总了Java中org.deidentifier.arx.risk.RiskModelPopulationUniqueness.PopulationUniquenessModel.DANKAR属性的典型用法代码示例。如果您正苦于以下问题:Java PopulationUniquenessModel.DANKAR属性的具体用法?Java PopulationUniquenessModel.DANKAR怎么用?Java PopulationUniquenessModel.DANKAR使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在org.deidentifier.arx.risk.RiskModelPopulationUniqueness.PopulationUniquenessModel的用法示例。


在下文中一共展示了PopulationUniquenessModel.DANKAR属性的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: isFulfilled

/**
 * We currently assume that at any time, at least one statistical model converges.
 * This might not be the case, and 0 may be returned instead. That's why we only
 * accept estimates of 0, if the number of equivalence classes of size 1 in the sample is also zero
 * 
 * @param distribution
 * @return
 */
protected boolean isFulfilled(HashGroupifyDistribution distribution) {

    RiskModelPopulationUniqueness riskModel = new RiskModelPopulationUniqueness(this.populationModel,
                                                                                distribution.getHistogram(),
                                                                                solverConfig);
    
    double populationUniques = 0d;
    if (this.statisticalModel == PopulationUniquenessModel.DANKAR) {
        populationUniques = riskModel.getFractionOfUniqueTuplesDankar(false);
    } else {
        populationUniques = riskModel.getFractionOfUniqueTuples(this.statisticalModel);
    }
    if (populationUniques > 0d && populationUniques <= getRiskThreshold()) {
        return true;
    } else if (populationUniques == 0d && distribution.getFractionOfRecordsInClassesOfSize(1) == 0d) {
        return true;
    } else {
        return false;
    }
}
 
开发者ID:arx-deidentifier,项目名称:arx,代码行数:28,代码来源:PopulationUniqueness.java

示例2: getPopulationUniquessModel

/**
 * Gets the PopulationUniqueness Model out of the Index
 * @param x The Index
 * @return The Population Uniqueness Model
 */
private PopulationUniquenessModel getPopulationUniquessModel(int x) {
	switch (x) {
	case 0:
		return PopulationUniquenessModel.DANKAR;
	case 1:
		return PopulationUniquenessModel.PITMAN;
	case 2:
		return PopulationUniquenessModel.ZAYATZ;
	default:
		return PopulationUniquenessModel.SNB;
	}
}
 
开发者ID:WiednerF,项目名称:ARXPlugin,代码行数:17,代码来源:ARXPluginProcess.java

示例3: PopulationUniqueness

/**
 * Creates a new instance of this criterion. Uses Dankar's method for estimating population uniqueness.
 * This constructor will clone the population model, making further changes to it will not influence
 * the results. The default accuracy is 10e-6 and the default maximal number of iterations is 1000.
 *  
 * @param riskThreshold
 * @param populationModel
 */
public PopulationUniqueness(double riskThreshold, ARXPopulationModel populationModel){
    this(riskThreshold, PopulationUniquenessModel.DANKAR, populationModel);
}
 
开发者ID:arx-deidentifier,项目名称:arx,代码行数:11,代码来源:PopulationUniqueness.java


注:本文中的org.deidentifier.arx.risk.RiskModelPopulationUniqueness.PopulationUniquenessModel.DANKAR属性示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。