ag-csw / LDStreamHMMLearn

1 stars 0 forks source link

Bug in nonstationary error estimation #36

Closed greenTara closed 7 years ago

greenTara commented 7 years ago

The time value that goes into the method .eval (on a qmm) when calculating the difference between the estimated transition matrix and the model transition matrix should be the time at the center of mass of the weight distribution. When current_time = window_size + k * self.shift -1

For the naive algorithm the center of mass is: dk =int((window_size-1)/2) estimation_time = current_time - dk

For the bayes algorithm this is: w = window_size s = shift dk = int(w -( s+1)/2 - w * math.pow(r, k+1)/2 ) estimation_time = current_time - dk

greenTara commented 7 years ago

See also the comments on issue #4

alexlafleur commented 7 years ago

When I change the formulas, the plots look like this:

Old script: dependence_bayes_error_qmm_delta 0 5

New script: dependence_bayes_error_qmm_delta_new 0 5

greenTara commented 7 years ago

ok, that's more like the expected result.

greenTara commented 7 years ago

This appears to be resolved.