The first part of this answer is nearly identical to that of @Marchi. The second part is not.
When the model appropriately fits the data (meaning the model assumptions are not wildly violated by features of the data), the follow code could be used:
nlm1 = NonlinearModelFit[data1, {model[x], cons}, params, x];
nlm2 = NonlinearModelFit[data2, {model[x], cons}, params, x];
mle1 = params /. nlm1["BestFitParameters"];
mle2 = params /. nlm2["BestFitParameters"];
var1 = Diagonal[nlm1["CovarianceMatrix"]];
var2 = Diagonal[nlm2["CovarianceMatrix"]];
z = (mle1 - mle2)/(var1 + var2)^0.5;
pvalues = 2 (1 - CDF[NormalDistribution[0, 1], Abs[z]]);
TableForm[Transpose[{mle1, mle2, var1^0.5, var2^0.5, z, pvalues}],
TableHeadings -> {{"A0", "B0", "za", "zb"},
{"MLE1", "MLE2", "Std.Err1", "Std.Err2", "z-value", "P-value"}}]
A normal distribution is used rather than a Student's t-distribution because the associated degrees of freedom is way over 100.
But all of this is contingent on the models providing an appropriate fit: a good fit is not required but rather an appropriate fit that accounts for the structure of the data is required. A special structure in the data is evident from a plot of the two datasets:
GraphicsRow[{ListPlot[data1, PlotLabel -> "Data 1", PlotRange -> {All, {-1.4, 0.1}}],
ListPlot[data2, PlotLabel -> "Data 2", PlotRange -> {All, {-1.4, 0.1}}]}]
We see that almost certainly that there were subjects/experimental units which had repeated measures which is not the error structure assumed by NonlinearModelFit
. This is more evident if the data is a bit restructured to highlight the consecutive measurements (but no changes in the ordering of the data nor any changes in the values of the data):
GraphicsRow[{ListPlot[data1, Joined -> True, PlotLabel -> "Data 1", PlotRange -> {All, {-1.4, 0.1}}],
ListPlot[data2, Joined -> True, PlotLabel -> "Data 2", PlotRange -> {All, {-1.4, 0.1}}]}]
An appropriate analysis needs to account for such repeated measures on various experimental units. Such regression models are called "Mixed Models" where there is more than one random term. As far as I know Mathematica does not offer any direct way of fitting such models. (Although I wish they would add such models.) One such model to fit such a structure is called a "Random coefficients model" where each subject/experimental unit has a random deviation from one or more of the coefficients.
In practice the maximum likelihood estimates of the coefficients are likely not to differ by very much even after accounting for the repeated measures. However, the associated standard errors might likely be very, very different and that affects the ability to make an appropriate assessment. So the above standard errors and P-values should be considered bogus.