builtin.gams {UCS}R Documentation

Built-in Generalised Association Measures (gam)


List available GAMs (generalised association measures) that can be computed with functions such as gam.score, add.gams and gam.iso, or test whether a specific GAM is available. Additional GAMs can be defined with the register.gam function.




  register.gam(name, equation, iso.equation=NULL)


names a character vector specifying the names of GAMs whose availability is tested
name a single character string specifying the name of a GAM that is defined or re-defined
equation a function that computes GAM scores from standard or ebo-coordinates (see below for details)
iso.equation an optional function that computes iso-surfaces in standard or ebo-coordinates (see below for details)


The names of built-in GAMs are identical to those of the corresponding standard AMs (e.g. t.score and chi.squared.corr).

The equation argument of register.gam, i.e. the equation defining a new GAM), must be a function with the signature (o, e, b, f, f1, f2, N). This function can computes GAM scores either from the ebo-coordinates e, b, o or from the standard coordinates f, f1, f2, N. It is always invoked with all seven arguments, which are guaranteed to be vectors of the same length, and must return a vector of corresponding GAM scores.

When an explicit equation for iso-surfaces \{g = γ\} exists, it can be made available through the optional argument iso.equation, which expects a function with the signature (gamma, e, b, f1, f2, N). Again, all six arguments are guaranteed to be vectors of the same length, and the function must return the corresponding o (or f) coordinates that satisfy the condition g(o, e, b) = γ (or g(f, f_1, f_2, N) = γ). When the iso.equation function is available for a GAM, it will be used by gam.iso for greater speed and accuracy. Otherwise, the iso surface is determined by a binary search algorithm (which has a unique solution for any semi-sound GAM).

The signatures of the equation and iso.equation functions are checked by register.gam, which will abort with an error message if they are not correct.


builtin.gams returns a character vector listing the names of available GAMs. is.builtin.gam returns a logical vector indicating which of the GAMs in the vector names are available.

See Also

builtin.ams, gam.score, add.gams, gam.iso, gam.helpers



all(is.builtin.gam(c("MI", "t.score", "chi.squared")))

             eq  = function (o, e, b, f, f1, f2, N) { log10(o^5 / e) },
             iso = function (gamma, e, b, f1, f2, N) { 10^(gamma/5) * e^(1/5) })

[Package UCS version 0.5 Index]