Std in matlab different from stdevp in excel
显示 更早的评论
I have an array of prices i calculated the standard deviation and the mean in matlab but the results are very different from what i calculated using excel. any reason why this is the case?
1 个评论
DGM
2022-7-25
Hi,
Today while submitting a last minute paper, I found out that discrepancy.
采纳的回答
更多回答(1 个)
Daniel Shub
2011-11-15
2 个投票
There are two ways to calculate the standard deviation. In Excel these are stdev and stdevp. In MATLAB they are std(x) and std(x, 1). The difference is the normalization factor (N or N-1). Look in the documentation of each to figure out which does which.
类别
在 帮助中心 和 File Exchange 中查找有关 Data Import from MATLAB 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!