nightscout / Trio

MIT License
64 stars 259 forks source link

Update PreferencesEditorStateModel.swift #143

Closed tmhastings closed 3 months ago

tmhastings commented 3 months ago

Correct pop up text for 'tddAdjBasal' from 7 days to 10 days

bjornoleh commented 3 months ago

I’m pretty sure it’s in fact 14 days :-)

tmhastings commented 3 months ago

There was quite a bit of research by @polscm32, @dnzxy, @MikePlante1, and myself to determine that it is actually 10, contrary to the minimized text and other references elsewhere.

bjornoleh commented 3 months ago

How so? This should be defined in determine-basal, no?

Edit: this should be the correct definition:

https://github.com/nightscout/open-iaps-oref/blob/487bcbba594b267070a1d5892c709251026c48e8/lib/determine-basal/determine-basal.js#L582

flyingpie101 commented 3 months ago

weird, in the other server, i think this was just being discussed. image

tmhastings commented 3 months ago

We determined that it's the TDD from oref2_variables that is passed to self.determineBasal. And in oref2_variables, TDD is determined this way:

10 days
bjornoleh commented 3 months ago

Ouch, alright, I stand corrected. I haven’t kept up with the “oref2” changes apparently.

dnzxy commented 3 months ago

It also doesn’t help, that the variable is called average14 and actually only covers 10 days of data…

MikePlante1 commented 3 months ago

Changed base to dev, now that alpha has been merged into dev.