EqualityConstr | R Documentation |
Setting of equality constraints on parameters.
heqa.SGB
sets the overall shape parameter to shape1
.
heqb.SGB
sets specified regression parameters to 0.
heqab.SGB
is a combination of both.
heqa.SGB.jac
, heqb.SGB.jac
, heqab.SGB.jac
compute the corresponding Jacobians.
heqa.SGB(x, d, u, bound, shape1, ...)
heqa.SGB.jac(x, ...)
heqb.SGB(x, d, u, bound, shape1, index, ...)
heqb.SGB.jac(x, d, u, bound, shape1, index, ...)
heqab.SGB(x, d, u, bound, shape1, index, ...)
heqab.SGB.jac(x, d, u, bound, shape1, index, ...)
x |
current vector of parameters ( |
d |
data matrix of explanatory variables (without constant vector) |
u |
data matrix of compositions (independent variables) |
bound |
not used. |
shape1 |
chosen fixed value of the overall shape parameter. |
index |
vector of length equal to the number of fixed parameters; specifies the indices of the fixed components in the vector of parameters |
... |
not used. |
These functions are invoked by regSGB
through the specification of the function name, shape1
and/or index
.
heqa.SGB
, heqb.SGB
, heqab.SGB
: vector of the same length as index
specifying the current value of x[index]
or x[1]-shape1
, where x
is the current vector of parameters. It should be near zero at convergence of the regression algorithm.
heqa.SGB.jac
, heqb.SGB.jac
, heqab.SGB.jac
: the corresponding jacobian matrices of dimensions length(index) \times length(x)
.
regSGB
, summary.regSGB
## parameter vector for a 3 parts composition with one explanatory variable (+ intercept):
x <- c(1,3.2,0.04,0.05,6,7:9)
## shape1 fixed to 1.5:
heqa.SGB(x,d,u,bound,1.5)
heqa.SGB.jac(x)
## Parameters 3 (first slope) and 4 (second intercept) fixed to 0:
heqb.SGB(x,d,u,bound,shape1,c(3,4))
heqb.SGB.jac(x,d,u,bound,shape1,c(3,4))
## Parameters 1, 3, 4 fixed to 1.5, 0, 0 respectively:
heqab.SGB(x,d,u,bound,1.5,c(1,3,4))
heqab.SGB.jac(x,d,u,bound,1.5,c(1,3,4))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.