Google literally did this during the pandemic
https://www.google.com/covid19/mobility/
So did apple:
https://www.apple.com/newsroom/2020/04/apple-makes-mobility-...
Only… they gave that information to government (supposedly post-analysis and anonymized). Regardless the data was quite literally used to “track and trace” then as a mechanism / justification to place you under house arrest.