谁能帮我?我的代码有一些警告。我该如何解决这些问题?输入是从 Matlab 中提取的简单向量 1*196608。
警告:
1: In empirical.distribution$dist.freq - benford.dist.freq :
longer object length is not a multiple of shorter object length
2: In ((empirical.distribution$dist.freq - benford.dist.freq)^2)/benford.dist.freq :
longer object length is not a multiple of shorter object length
3: In empirical.distribution$dist - benford.dist :
longer object length is not a multiple of shorter object length
4: In as.data.table.list(x, keep.rownames = keep.rownames, ... :
Item 1 has 9 rows but longest item has 10; recycled with remainder
我的代码:
library(benford.analysis)
library(R.matlab)
f=readMat('vectorimage.mat')
s=f$vectorimage
y=as.numeric(s);#convert to numeric type
d=benford(y,number.of.digits = 1)
print(d)
plot(d)