matdiv — matrix quotient
[out]=matdiv(x,y)
x,y = two matrices (not of the same dimension but that are row or column compatible)
out = x./y where x and y are row or column compatible
1) x1=ones(7,1);x2=[1:7]';y = lag([x1 x2],1,4);z=0.5*ones(7,1);matdiv(x,z) 2) w = matdiv(x,resid); Example 1 gives the matrix: ! 8. 8. ! ! 2. 2. ! ! 2. 4. ! ! 2. 6. ! ! 2. 8. ! ! 2. 10. ! ! 2. 12. ! Example 2 (taken from lad) makes the term by term division of each column of matrix x ((nxk) matrix of exogenous variables) by the (nx1) vector of absolute residuals from the ols regression of y on x.