NMinimize[]
with the Automatic method works nice ... sometimes.
You can help it by providing a better choice. Like in:
ts1 = {{682, 98}, {739, 165}, {784, 286}, {826, 470}, {850, 618}, {871, 779}};
ts2 = {{683, 92}, {739, 174}, {785, 299}, {827, 489}, {851, 637}, {871, 807}};
tt = {ts1, ts2};
nlm = NonlinearModelFit[#, a Exp[b t];, {a, b}, t,
Method -> {"NMinimize", {Method -> "SimulatedAnnealing"}}] & /@ tt;
nlm[[#]]["BestFitParameters"] & /@ {1, 2}
(* {{a -> 0.0368246, b -> 0.0114384}, {a -> 0.0348901, b -> 0.0115362}} *)
The default was probably using "DifferentialEvolution", as you can see here:
nlm = NonlinearModelFit[#, a Exp[b t], {a, b}, t, Method -> {"NMinimize"}] & /@ tt;
nlm[[#]]["BestFitParameters"] & /@ {1, 2}
NMinimize[Total[(a Exp[b #[[1]]] - #[[2]])^2 & /@ #], {a, b},
Method -> {"DifferentialEvolution"}] & /@ tt
(* {{a -> 9.60194, b -> 0.00477938}, {a -> 0.03489, b -> 0.0115362}}
{{95044.8, {a -> 9.60194, b -> 0.00477938}},
{27.3624, {a -> 0.0348901, b -> 0.0115362}}}
*)
But the problem is that the function is very flat in the region of interest:
GraphicsRow[
ContourPlot[Total[(a Exp[b #[[1]]] - #[[2]])^2 & /@ #], {a, 0, 10}, {b, 0, .01},
AspectRatio -> 1] & /@ tt]
So, this is what is happening with the convergence:
ptsk = Reap[NMinimize[Total[(a Exp[b #[[1]]] - #[[2]])^2 & /@ #], {a, b},
Method -> {"DifferentialEvolution"},
StepMonitor :> Sow[{a, b}]]][[2, 1]] & /@ tt;
GraphicsRow[ContourPlot[
Total[(a Exp[b #[[1]]] - #[[2]])^2 & /@ #[[1]]], {a, 0, 14}, {b, 0, .02}, AspectRatio -> 1,
Epilog -> {Red, Arrow /@ Partition[#[[2]], 2, 1]}] & /@ Transpose[{tt, ptsk}]]
Possibly a very small bump in a very flat surface is causing a large difference.
A more detailed view, where you can see the "return point" for the convergence:
NonlinearModelFit[ts, a Exp[b t], {a, {b, 1/800}}, t]
. Doesn't work withMethod -> "NMinimize"
though, which ignores it. $\endgroup$