fpNOr, fpNAnd, fpNOff {fingerprint}R Documentation

These functions evaluate the number of bits in various conditions

Description

These functions evaluate the number of bits common (i.e., set or unset) between two fingerprints. These are mainly used to evaluate the various distance metrics. So for two fingerprints A and B we have

fpNOr
Number of bits on in A but not on in B
fpNAnd
Number of bits on in A that are also on in B
fpNOff
Number of bits off in A that are also off in B

Usage

fpNOr(fp1, fp2, size=1024)
fpNAnd(fp1, fp2, size=1024)
fpNOff(fp1, fp2, size=1024)

Arguments

fp1 A fingerprint vector
fp2 A fingerprint vector
size The length of the fingerprints represented by the fingerprint vectors

Value

An integer indicating the number of bits for the specific condition

Author(s)

Rajarshi Guha rguha@indiana.edu

Examples

# make 2 fingerprints
fp1 <- fp.from.bstring("11001011")
fp2 <- fp.from.bstring("11010100")
fpNOr(fp1,fp2,8)
fpNAnd(fp1,fp2,8)
fpNOff(fp1,fp2,8)

[Package fingerprint version 1.6 Index]