1.0.4 • Published 6 years ago

node-mondrian v1.0.4

Weekly downloads
4
License
MIT
Repository
github
Last release
6 years ago

Node-mondrian Build Status

Brings k-anonymity and l-diversity to nodeJS by using Mondrian and Mondrian_L_Diversity under the hood.

Developed as part of the Privacy Engineering course at the Technische Universität Berlin.

Usage

Install

npm install node-mondrian

Example

const Mondrian = require('node-mondrian')

// See this repo for example data
const data = require('data/adult.json')
const attributes = require('data/adult-attributes.json')

let anonymized = await Mondrian.kAnonymity(data, attributes, 10) 
let diversified = await Mondrian.lDiversity(data, attributes, 10)

Results in:

[
  {
    "age": "28,53",
    "workclass": "*",
    "educationNum": "5,14",
    "maritalStatus": "*",
    "race": "*",
    "sex": "*",
    "nativeCountry": "*",
    "occupation": "Adm-clerical"
  },
  {
    "age": "28,53",
    "workclass": "*",
    "educationNum": "5,14",
    "maritalStatus": "*",

Testing

npm test
1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago