Learn R Programming

MoLE (version 1.0.1)

VMATCH: Compare vectors

Description

Compare vectors properly taking into account uniform vectors (with same values on all dimensions) and non-specified dimensions.

Usage

VMATCH(x, y, incomparable = 0, noise=TRUE)

Arguments

x

target vector

y

vector (numeric or data frame/list) or set of vectors whose similarity to the target is to be determined

incomparable

Value to be returned for incomparable vectors, in which all dimension pairs contain underspecified values

noise

logical for addition of noise to outcome (default is TRUE)

Value

numeric

Details

Differences between vectors are determined per dimension, weighted (cf. world$weigh), and then averaged. If vectors are not specified for certain target dimensions, this does not count as a mismatch.

See Also

ACTOR, NOUNS, SITUATION, SELECTVERB, SELECTACTOR, SELECTUNDERGOER, PROPOSITION, REFCHECK, TOPICCOPY, GENERALIZE, CHECKSUCCESS, ANALYZE, TYPEMATCH, NOUNMORPHOLOGY, VERBMORPHOLOGY, INTERPRET.INT, SUCCESS, PERSONUPDATE, FUSE, SEMUPDATE

Examples

Run this code
# NOT RUN {
FOUND()
vectors=head(population[[1]]$nouns[,1:9])
target=vectors[1,]
vectors[2,]=NA
VMATCH(target, vectors)
# }

Run the code above in your browser using DataLab