Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想计算使用 gps 信号行进距离的平均速度。
这个公式是否计算正确的平均速度?
avgspeed = totalspeed/count
其中 count 是 gps 信号的数量。
如果有错误,请任何人告诉我正确的公式。
虽然这应该可行,但请记住,如果您在不同的地形中,GPS 信号很容易混淆。因此,我不会使用算术平均值,而是计算中位数,因此异常值(快速跳跃)不会对结果产生如此大的影响。
来自维基百科(n 是信号的数量):
如果 n 是奇数,则中位数 (M) = 第 ((n + 1)/2) 项的值。 如果 n 是偶数,则中位数 (M) = [((n)/2)th item term + ((n)/2 + 1)th item term ]/2 的值
如果 n 是奇数,则中位数 (M) = 第 ((n + 1)/2) 项的值。
如果 n 是偶数,则中位数 (M) = [((n)/2)th item term + ((n)/2 + 1)th item term ]/2 的值