Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- x={{0,0.17},{1,0.05},{2,0.07},{3,-0.03},{4,0.15},{5,0.18},{6,0.03},{7,0.13},{8,0.09},{12,0.42},{13,0.71},{14,0.65},{15,0.61},{16,0.42},{17,0.21},{18,0.26},{19,0.32},{20,0.3},{24,0.26},{25,0.31},{26,0.18},{27,0.19},{28,0.33},{29,0.09},{30,0.17},{31,0.3},{32,0.4},{36,0.15},{37,0.09},{38,0.15},{39,0.09},{40,0.04},{41,0.07},{42,0.17},{43,0.06},{44,-0.03},{48,0.24},{49,0.22},{50,0.22},{51,0.33},{52,0.2},{53,0.34},{54,0.26},{55,0.26},{56,0.45},{60,0.43},{61,0.6},{62,0.35},{63,0.26},{64,0.42},{65,0.3},{66,0.31},{67,0.3},{68,0.41},{72,0.13},{73,0.2},{74,-0.0},{75,-0.04},{76,0.09},{77,-0.0},{78,0.21},{79,0.18},{80,0.26},{84,0.03},{85,0.0},{86,0.15},{87,0.27},{88,0.18},{89,0.06},{90,0.36},{91,0.28},{92,0.25},{96,-0.04},{97,0.09},{98,0.2},{99,0.18},{100,0.37},{101,0.38},{102,0.64},{103,0.7},{104,0.9}};
- LinearFitForm[k_]:=a+b*k;
- linearFitParams=Association[FindFit[x,LinearFitForm[k],{a,b},k]];
- LinearFitFn[k_]:=LinearFitForm[k]/.linearFitParams;
- Show[Plot[LinearFitFn[k],{k,0,104},PlotStyle->{Black,Thin},AxesLabel->{"Month","\[CapitalDelta]T"},PlotRange->{-0.2,1}],ListPlot[x,Joined->True,PlotStyle->{Red}]]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement