Clueed / tendenz

https://tendenz.vercel.app
Other
3 stars 1 forks source link

Handle splits #28

Closed Clueed closed 1 year ago

Clueed commented 1 year ago

Current theory (needs research): Polygon adjusts historical data for splits. This is why updateMarket was running today longer then it should - it wasn't a bug after all.

Depending on how frequent splits are this might be fine. For now it only delays sigma calculation by 12 * 500 / 60 = 100min which is fine. Eventually it makes sense to detect splits and only adjust those stock historically.

What is a problem on the other hand is that those historical priced are only available for 2 year while the dataset can include more. Thus, sigma calc should be limited to 2 year back as a temporary fix.