Here is the data: x1=[2198,6000,2198,6000, 2198,6000,2198,6000, 2198,6000,2198,6000, 2198,6000,2198,6000]'; x2=[2348,2348,4000,4000, 2348,2348,4000,4000, 2348,2348,4000,4000, 2348,2348,4000,4000]'; x3=[2348,2348,2348,2348,8000,8000,8000,8000, 2348,2348,2348,2348,8000,8000,8000,8000]'; x4=[2348,2348,2348,2348, 2348,2348,2348,2348,4078,4078,4078,4078, 4078,4078,4078,4078]'; X=[x1 x2 x3 x4 ]; Stress=[248,269,250,271,240,247,244,268,249,278,251,283,240,253,246,270]';
Below is the algorithm: D = x2fx(X, 'interaction'); b = regress(Stress,D); format short e t = stats.tstat; CoeffTable = dataset({t.beta,'coef'},{t.se,'StdErr'},{t.t,'tStat'},{t.pval,'pVal'})
The error message is: ??? Undefined variable "stats" or class "stats.tstat".
Thanks Tom