Package 'dynetNLAResistance'

Title: Resisting Neighbor Label Attack in a Dynamic Network
Description: An anonymization algorithm to resist neighbor label attack in a dynamic network.
Authors: Jiaqi Tang
Maintainer: Jiaqi Tang <[email protected]>
License: MIT + file LICENSE
Version: 0.1.0
Built: 2025-03-01 05:37:23 UTC
Source: https://github.com/s1107967177/dynetnlaresistance

Help Index


Anonymize a snapshot of a dynamic network.

Description

Anonymize a snapshot of a dynamic network.

Usage

anonymization(g, alpha = 1, beta = 2, gamma = 3)

Arguments

g

A network grouped by lw-grouping algorithm.

alpha

Weight of anonymization cost resulted from label generalization.

beta

Weight of anonymization cost resulted from adding edges.

gamma

Weight of anonymization cost resulted from adding nodes.


Anonymize two node.

Description

Anonymize two node.

Usage

anonymize2node(g, uid, vid, noise = g$noise)

Arguments

g

A graph contains vertexs with different labels and some of which are sensitive.

uid

Name of a node with sensitive label.

vid

Name of a node with unsensitive label.

noise

Current amount of noise nodes.

Value

A list with information of anonymized network.


Calculate anonymization cost of two nodes.

Description

Calculate anonymization cost of two nodes.

Usage

cost(g, uid, vid, alpha = 1, beta = 2, gamma = 3)

Arguments

g

A graph contains vertexs with different labels and some of which are sensitive.

uid

Name of a node with sensitive label.

vid

Name of a node with unsensitive label.

alpha

Weight of anonymization cost resulted from label generalization.

beta

Weight of anonymization cost resulted from adding edges.

gamma

Weight of anonymization cost resulted from adding nodes.

Value

Anonymization cost of two nodes.


Draw a graph contains vertexs with sensitive or unsensitive label

Description

Draw a graph contains vertexs with sensitive or unsensitive label

Usage

draw.graph(g, main = NULL, label = NA)

Arguments

g

A graph contains vertexs with different labels and some of which are sensitive.

main

The title of graph.

label

Label of vertexs.

Examples

dynet <- make.virtual.dynamic.network()
draw.graph(dynet$t1)

Generate a grouped dynamic network by lw-grouping algorithm.

Description

Generate a grouped dynamic network by lw-grouping algorithm.

Usage

lw.grouping(dynet = NULL, l = 2, w = 3)

Arguments

dynet

An ungrouped dynamic network.

l

Kinds of labels in each unmerged group.

w

Width of window of lw-grouping algorithm.

Value

A list of grouped network with attribute of gs.merged.


Make a vertex-increasing virtual dynamic network.

Description

Make a vertex-increasing virtual dynamic network.

Usage

make.virtual.dynamic.network(network.data = NULL, len = 10, by = 5,
  label.types = 100, prop.init = 0.001, prop.sensitive = 0.1)

Arguments

network.data

A data frame containing a symbolic edge list,which contains the information of whole network data.

len

Time of this dynamic network lasts.

by

The number of vertex added in network each time.

label.types

The number of label types the network possesses.

prop.init

The proportion of vertex amounts of initial network in whole network data.

prop.sensitive

The proportion of amounts of vertex with sensitive label in whole network data.

Value

A list of snapshots of a virtual dynamic network.

Examples

dynet <- make.virtual.dynamic.network()

Unirected graph: CA-CondMat

Description

Collaboration network of Arxiv Condensed Matter category (there is an edge if authors coauthored at least one paper) network

Usage

network

Format

An object of class data.frame with 93439 rows and 2 columns.

Details

@format A data frame with 93439 rows and 2 variables: