The following Matlab project contains the source code and Matlab examples used for linear deming regression.
[ b sigma2_x x_est y_est stats] = deming(x,y,lambda,alpha)
deming() performs a linear Deming regression to find the linear coefficients:
y = b(1) + b(2)*x
under the assumptions that x and y *both* contain measurement error with measurement error variance related as lambda = sigma2_y/sigma2_x (sigma2_x and sigma2_y is the measurement error variance of the x and y variables, respectively).