eq2xcol Multivariate regressions exploeqs

Grocer >> Multivariate regressions > eqlist

eqlist

recovers objects names in an equation

CALLING SEQUENCE

[namey,ncoefeqi,lexo]=eqlist(eq,coef)

PARAMETERS

Input

• eq = a string of the form : 'varendo=coefi*varex1+…+coefj*varexk' with varexi possibly lacking

• coef = a string vector of the form coef=['coef1';…;'coefn']

Output

• namey = the name of the rhs variable

• ncoefeqi = a (nx1) vector of the indexes of coefi,…,coefj in coef

• lexo = a (nx1) vector of names of the exogenous variables

DESCRIPTION

Recovers from an equation the name of the endogenous variable, the indexes of the coefficients (in a vector) and the names of the exogenous variables (also in a vector).

EXAMPLE

[nyi,ncoefi,lexoi]=eqlist('y1=c1*x1+c2*x2',['c1';'c2'])
 
//Extracts in nyi y1, in ncoefi [1;2] and in lexoi ['x1';'x2'].

AUTHOR

Eric Dubois 2002
eq2xcol Multivariate regressions exploeqs