Allin Cottrell,
Tks for the reply
d1 is another data series and not the fit value from d1 = b[1] * d2 + b[2] * d3
Want to regress d1 against d2 and d3 and find a d1^hat approximating d1
Ols uses error minimization but want to use maximisation of t value from the adf of
d1^hat
Using the script you provide, the original d1 data series is replace from the d1^hat
Clarodina