I have array data. Let's say time, x, and y. They are all 117*1 array. Then i make plots. And then i add a trendline for each plot using polyfit.
aa=polyfit(time,x,1);bb=polyval(aa,time);figureplot(time,x)hold on plot(time,bb)cc=polyfit(time,y,1);dd=polyval(cc,time);figureplot(time,y)hold onplot(time,dd)
So then i have 2 figures with 2 trendlines. I have a trouble about how to combine these two trendline in one figure. So that i can calculate the angle between the trendlines. Thank you..
Best Answer