Need expert statistical support?

More Info

Module

asreml.model_function_info

Descriptions of the model functions used in formula strings.

This is a dummy module, for documentation purposes only.

Members

function

offset

#
def offset(variable_name):

An offset term to add to the linear model, only used in the case of binomial or Poisson data.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
function

con

#
def con(variable_name):

Sum to zero constraints.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
function

lin

#
def lin(variable_name):

Create a variate from variable_namej (usually factors).

Arguments:
  • variable_name: The name of a variable in the primary dataset.
function

pow

#
def pow(variable_name, p=1, offset=0):

Create the model term: (variable_name+offset)^p.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • p: The exponent in a power function term (pow).
  • offset: Constant added to variable_name.
function

pol

#
def pol(variable_name, t=1):

Orthogonal polynomials.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • t: The maximum degree of a set of orthogonal polynomials formed from variable_name. If negative, the intercept polynomial is omitted.
function

leg

#
def leg(variable_name, t=1):

Legendre polynomials.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • t: The maximum degree of a set of Legendre polynomials formed from variable_name. If negative, the intercept polynomial is omitted.
function

spl

#
def spl(variable_name, k=0):

Cubic smoothing spline (random component).

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • k: The number of equally-spaced knot points for a cubic smoothing spline. If zero or omitted, k is set to the optional argument knots (see asreml.set_options).
function

dev

#
def dev(variable_name, init=None):

Spline deviations; create a factor from the supplied variate.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • init: A vector of initial values.
function

at

#
def at(variable_name, lvls=None):

Form a conditioning covariate from variable_name for each level of variable_name specified in the lvls argument.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • lvls: Vector of levels of the conditioning factor (variable_name) that define the conditioning covariates formed by at. If numeric, lvls indexes the levels vector of variable_name.
function

sat

#
def sat(variable_name, lvls=None):

Section at.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • lvls: Vector of levels for sectioning at.
function

fac

#
def fac(x, y=None):

Create a factor.

Arguments:
  • x: The name of a variable in the primary dataset.
  • y: The name of a variable in the primary dataset.
function

and

#
def and(variable_name, times=1):

Multiply the design matrix for variable_name by times and add it to the preceding design matrix.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • times: Number of multiples (may be non-integer) of the design matrix for variable_name to add to the preceding design matrix.
function

grp

#
def grp(variable_name):

Create a model term from covariates held in specific columns of the primary dataset.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
function

id

#
def id(variable_name):

Correlation model (no variance associated).

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
function

idv

#
def idv(variable_name, init=None):

Variance model.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values.
function

idh

#
def idh(variable_name, init=None):

Identity (diagonal) variance model.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values.
function

ar1

#
def ar1(variable_name, init=None):

Autoregressive model of order 1; correlation form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ar1v

#
def ar1v(variable_name, init=None):

Autoregressive model of order 1; homogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ar1h

#
def ar1h(variable_name, init=None):

Autoregressive model of order 1; heterogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ar2

#
def ar2(variable_name, init=None):

Autoregressive model of order 2; correlation form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ar2v

#
def ar2v(variable_name, init=None):

Autoregressive model of order 2; homogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ar2h

#
def ar2h(variable_name, init=None):

Autoregressive model of order 2; heterogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ar3

#
def ar3(variable_name, init=None):

Autoregressive model of order 3; correlation form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ar3v

#
def ar3v(variable_name, init=None):

Autoregressive model of order 3; homogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ar3h

#
def ar3h(variable_name, init=None):

Autoregressive model of order 3; heterogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

sar

#
def sar(variable_name, init=None):

Symmetric autoregressive model; correlation form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

sarv

#
def sarv(variable_name, init=None):

Symmetric autoregressive model; homogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

sarh

#
def sarh(variable_name, init=None):

Symmetric autoregressive model; heterogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

sar2

#
def sar2(variable_name, init=None):

Constrained autoregressive model of order 2; correlation form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

sar2v

#
def sar2v(variable_name, init=None):

Constrained autoregressive model of order 2; homogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

sar2h

#
def sar2h(variable_name, init=None):

Constrained autoregressive model of order 2; heterogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ma1

#
def ma1(variable_name, init=None):

Moving average model of order 1; correlation form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ma1v

#
def ma1v(variable_name, init=None):

Moving average model of order 1; homogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ma1h

#
def ma1h(variable_name, init=None):

Moving average model of order 1; heterogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ma2

#
def ma2(variable_name, init=None):

Moving average model of order 2; correlation form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ma2v

#
def ma2v(variable_name, init=None):

Moving average model of order 2; homogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

ma2h

#
def ma2h(variable_name, init=None):

Moving average model of order 2; heterogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

arma

#
def arma(variable_name, init=None):

Autoregressive-moving average model; correlation form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

armav

#
def armav(variable_name, init=None):

Autoregressive-moving average model; homogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

armah

#
def armah(variable_name, init=None):

Autoregressive-moving average model; heterogeneous variance form.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters.
function

cor

#
def cor(variable_name, init=None):

Simple correlation model; correlation form.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

corv

#
def corv(variable_name, init=None):

Simple correlation model; homogeneous variance form.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

corh

#
def corh(variable_name, init=None):

Simple correlation model; heterogeneous variance form.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

corb

#
def corb(variable_name, b=1, init=None):

Banded correlation model with b bands; correlation form.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • b: Number of (sub-diagonal) bands in banded correlation models.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

corbv

#
def corbv(variable_name, b=1, init=None):

Banded correlation model with b bands; homogeneous variance form.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • b: Number of (sub-diagonal) bands in banded correlation models.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

corbh

#
def corbh(variable_name, b=1, init=None):

Banded correlation model with b bands, heterogeneous variance form.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • b: Number of (sub-diagonal) bands in banded correlation models.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

corg

#
def corg(variable_name, init=None):

General correlation model; correlation form.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

corgv

#
def corgv(variable_name, init=None):

General correlation model; homogeneous variance form.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

corgh

#
def corgh(variable_name, init=None):

General correlation model; heterogeneous variance form.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

diag

#
def diag(variable_name, init=None):

Diagonal variance model.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

us

#
def us(variable_name, init=None):

Unstructured variance model.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

chol

#
def chol(variable_name, k=1, init=None):

Cholesky variance model of order k.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • k: Order of the model.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

cholc

#
def cholc(variable_name, k=1, init=None):

Cholesky C variance model of order k.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • k: Order of the model.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

ante

#
def ante(variable_name, k=1, init=None):

Antedependence variance model of order k.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • k: Order of the model.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

sfa

#
def sfa(variable_name, k=1, init=None):

Factor analytic model with k factors; the variance-covariance matrix is modelled on the correlation scale.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • k: Order of the model.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

facv

#
def facv(variable_name, k=1, init=None):

Factor analytic model with k factors; the variance-covariance matrix is modelled on the covariance" scale.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • k: Order of the model.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

fa

#
def fa(variable_name, k, init=None):

Factor analytic model with k factors; sparse formulation where k extra levels are inserted in the mixed model equations.

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • k: Number of factors.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

rr

#
def rr(variable_name, k, init=None):

Factor analytic model with k factors; reduced rank formulation of fa() where the default boundary constraints for the specific variances are set to F (fixed).

Arguments:
  • variable_name: The name of a variable in the primary dataset.
  • k: Number of factors.
  • init: A vector of initial values (correlation parameters followed by variance parameters).
function

exp

#
def exp(x, init=None, dist=None):

Exponential (or power) model; correlation form.

Arguments:
  • x: The name of a variable in the primary datset.
  • init: A vector of initial values (power parameters followed by variance parameters).
  • dist: Numeric vector of coordinates (distances). If missing then the distances are obtained as unique(obj).
function

expv

#
def expv(x, init=None, dist=None):

Exponential (or power) model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary datset.
  • init: A vector of initial values (power parameters followed by variance parameters).
  • dist: Numeric vector of coordinates (distances). If missing then the distances are obtained as unique(obj).
function

exph

#
def exph(x, init=None, dist=None):

Exponential (or power) model; heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary datset.
  • init: A vector of initial values (power parameters followed by variance parameters).
  • dist: Numeric vector of coordinates (distances). If missing then the distances are obtained as unique(obj).
function

gau

#
def gau(x, init=None, dist=None):

Gaussian power model; correlation form.

Arguments:
  • x: The name of a variable in the primary datset.
  • init: A vector of initial values (power parameters followed by variance parameters).
  • dist: Numeric vector of coordinates (distances). If missing then the distances are obtained as unique(obj).
function

gauv

#
def gauv(x, init=None, dist=None):

Gaussian power model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary datset.
  • init: A vector of initial values (power parameters followed by variance parameters).
  • dist: Numeric vector of coordinates (distances). If missing then the distances are obtained as unique(obj).
function

gauh

#
def gauh(x, init=None, dist=None):

Gaussian power model; heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary datset.
  • init: A vector of initial values (power parameters followed by variance parameters).
  • dist: Numeric vector of coordinates (distances). If missing then the distances are obtained as unique(obj).
function

lvr

#
def lvr(x, init=None, dist=None):

Linear variance model; correlation form.

Arguments:
  • x: The name of a variable in the primary datset.
  • init: A vector of initial values (power parameters followed by variance parameters).
  • dist: Numeric vector of coordinates (distances). If missing then the distances are obtained as unique(obj).
function

lvrv

#
def lvrv(x, init=None, dist=None):

Linear variance model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary datset.
  • init: A vector of initial values (power parameters followed by variance parameters).
  • dist: Numeric vector of coordinates (distances). If missing then the distances are obtained as unique(obj).
function

lvrh

#
def lvrh(x, init=None, dist=None):

Linear variance model; heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary datset.
  • init: A vector of initial values (power parameters followed by variance parameters).
  • dist: Numeric vector of coordinates (distances). If missing then the distances are obtained as unique(obj).
function

iexp

#
def iexp(x, y, init=None):

Exponential (or power) model; correlation form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

iexpv

#
def iexpv(x, y, init=None):

Exponential (or power) model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

iexph

#
def iexph(x, y, init=None):

Exponential (or power) model; heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

aexp

#
def aexp(x, y, init=None):

Anisotropic exponential variance model; correlation form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

aexpv

#
def aexpv(x, y, init=None):

Anisotropic exponential variance model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

aexph

#
def aexph(x, y, init=None):

Anisotropic exponential variance model; heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

igau

#
def igau(x, y, init=None):

Isotropic Gaussian variance model; correlation form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

igauv

#
def igauv(x, y, init=None):

Isotropic Gaussian variance model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

igauh

#
def igauh(x, y, init=None):

Isotropic Gaussian variance model; heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

agau

#
def agau(x, y, init=None):

Anisotropic Gaussian variance model; correlation form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

agauv

#
def agauv(x, y, init=None):

Anisotropic Gaussian variance model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

agauh

#
def agauh(x, y, init=None):

Anisotropic Gaussian variance model; heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

ieuc

#
def ieuc(x, y, init=None):

Isotropic Euclidean variance model; correlation form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

ieucv

#
def ieucv(x, y, init=None):

Isotropic Euclidean variance model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

ieuch

#
def ieuch(x, y, init=None):

Isotropic Euclidean variance model; heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

ilv

#
def ilv(x, y, init=None):

Isotropic linear variance model; correlation form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

ilvv

#
def ilvv(x, y, init=None):

Isotropic linear variance model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

ilvh

#
def ilvh(x, y, init=None):

Isotropic linear variance model;" heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

sph

#
def sph(x, y, init=None):

Spherical variance model; correlation form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

sphv

#
def sphv(x, y, init=None):

Spherical variance model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

sphh

#
def sphh(x, y, init=None):

Spherical variance model; heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

cir

#
def cir(x, y, init=None):

Circular variance model; correlation form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

cirv

#
def cirv(x, y, init=None):

Circular variance model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

cirh

#
def cirh(x, y, init=None):

Circular variance model; heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary dataset containing the x coordinates.
  • y: The name of a variable in the primary dataset containing the y coordinates.
  • init: A vector of initial values (power parameters followed by variance parameters).
function

mtrn

#
def mtrn(x, y, phi=None, nu=0.5, delta=1, alpha=0, lambda=2):

Matern variance model; correlation form.

Arguments:
  • x: The name of a variable in the primary datatset containing the x coordinates.
  • y: The name of a variable in the primary datatset containing the y coordinates.
  • phi: The range parameter.
  • nu: The smoothness parameter.
  • delta: Governs geometric anisotropy.
  • alpha: Governs geometric anisotropy.
  • lambda: Specifies the choice of metric. Options are 1 for city block, and 2 for Euclidean distance.
function

mtrnv

#
def mtrnv(x, y, phi=None, nu=0.5, delta=1, alpha=0, lambda=2, init=0.1):

Matern variance model; homogeneous variance form.

Arguments:
  • x: The name of a variable in the primary datatset containing the x coordinates.
  • y: The name of a variable in the primary datatset containing the y coordinates.
  • phi: The range parameter.
  • nu: The smoothness parameter.
  • delta: Governs geometric anisotropy.
  • alpha: Governs geometric anisotropy.
  • lambda: Specifies the choice of metric. Options are 1 for city block, and 2 for Euclidean distance.
  • init: A vector of initial values.
function

mtrnh

#
def mtrnh(x, y, phi=None, nu=0.5, delta=1, alpha=0, lambda=2, init=0.1):

Matern variance model; heterogeneous variance form.

Arguments:
  • x: The name of a variable in the primary datatset containing the x coordinates.
  • y: The name of a variable in the primary datatset containing the y coordinates.
  • phi: The range parameter.
  • nu: The smoothness parameter.
  • delta: Governs geometric anisotropy.
  • alpha: Governs geometric anisotropy.
  • lambda: Specifies the choice of metric. Options are 1 for city block, and 2 for Euclidean distance.
  • init: A vector of initial values.
function

str

#
def str(form, vmodel):

Variance structure spanning several model terms.

Arguments:
  • form: A model formula included verbatim in the asreml random argument.
  • vmodel: A direct product variance model for the set of terms given in form.
function

vm

#
def vm(variable_name, source, singG='PD', invert=False, ldet=0.0):

Create a model term associating a known relationship structure in source with a factor in the primary dataset.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • source: The known inverse of a relationship matrix in the form of a lower triangular sparse matrix held in three-column coordinate form in row-major order. See asreml.ainverse for more details.
  • singG: A string giving the state of the supplied inverse relationship matrix:
    • "PD": source is positive definite.
    • "ND": source is non-singular indefinite (positive and negative roots). In this case asreml ignores the indefinite condition and proceeds.
    • "PSD": source is positive semi-definite. In this case, asreml proceeds using Lagrange multipliers to process the matrix. Two cases arise: whether the singularity arises because an effect has zero variance or whether it arises as a linear dependence. An example of the first is when the genomic relationship matrix represents a dominance matrix, and the list of genotypes includes fully inbred individuals (which by definition have no dominance). An example of the second is when the list of genotypes includes clones.
    • "NSD": source is singular indefinite (positive, zero and negative roots). The indefinite condition is ignored and asreml proceeds using Lagrange multipliers as for "PSD" matrices.
  • invert: If true, then the matrix supplied in source will be inverted before being used.
  • ldet: The log determinant of the matrix supplied in source. If not supplied the log determinant will be calculated (this can numerically intensive).
function

ide

#
def ide(variable_name, source):

Create a term with the levels of vm, and modelled by the homogeneous form of the identity variance structure. The vm term must precede ide in the model for the factor levels to be found.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • source: The known inverse of a relationship matrix in the form of a lower triangular sparse matrix held in three-column coordinate form in row-major order. See asreml.ainverse for more details.
function

ric

#
def ric(variable_name, source, singG='PD', init=[0.2, 0.1]):

Create a model term associating a known relationship structure in source and residual additive genetic effects with a factor in the primary dataset.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • source: The known inverse of a relationship matrix in the form of a lower triangular sparse matrix held in three-column coordinate form in row-major order. See asreml.ainverse for more details.
  • singG: singG: A string giving the state of the supplied inverse relationship matrix:
    • "PD": source is positive definite.
    • "ND": source is non-singular indefinite (positive and negative roots). In this case asreml ignores the indefinite condition and proceeds.
    • "PSD": source is positive semi-definite. In this case, asreml proceeds using Lagrange multipliers to process the matrix. Two cases arise: whether the singularity arises because an effect has zero variance or whether it arises as a linear dependence. An example of the first is when the genomic relationship matrix represents a dominance matrix, and the list of genotypes includes fully inbred individuals (which by definition have no dominance). An example of the second is when the list of genotypes includes clones.
    • "NSD": source is singular indefinite (positive, zero and negative roots). The indefinite condition is ignored and asreml proceeds using Lagrange multipliers as for "PSD" matrices.
  • init: A vector of initial values.
function

zero

#
def zero(k):

Includes the specified number of columns of zeros in the model.

Arguments:
  • k: Number of zero columns to include in the model.
function

dsum

#
def dsum(model, cond, levels=None):

Direct sum structures for residual models.

Arguments:
  • model: A formula of the form A+B+..., where A and B define variance matrices for simple or compound model terms.
  • cond: A simple conditioning factor whose levels identify and determine the number of sub-matrices in the direct sum.
  • levels: A list of the length of the number of terms in the left-hand side of model that are separated by +. The components of levels are vectors of unique values of Z. If there is only one term in the left-hand side of model (or if the context allows, see examples) then levels may be a vector. If levels is numeric, then these are ordinal numbers that refer to the sections defined by Z in unique(Z) order. If None then unique(Z) is used.
function

mthr

#
def mthr(variable_name, init=None):

Multinomial threshold model.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • init: A vector of initial values.
function

uni

#
def uni(variable_name, k=0, n=None):

Forms a factor with a level for each record where factor level of variable_name is k.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.
  • k: The level of variable_name to define the new factor at.
  • n: The size of the model term, defaults to the number of records.
function

vect

#
def vect(variable_name):

Is used in a multivariate analysis on a multivariate set of covariates to pair them with the variates.

Arguments:
  • variable_name: The name of a categorical variable / factor in the primary dataset.

Want to sharpen your statistics skills?

Browse Courses