基本R的expand.grid()的错误/奇数

时间:2019-09-25 16:35:02

标签: r seq

a <- expand.grid(seq(from = 0.5, to = 5, by = 0.1),
            seq(from = 0.5, to = 5, by = 0.1))
a[a$Var1 == 1.6, ] # works 
a[a$Var1 == 1.7, ] # 0 rows
a[a$Var1 == 1.8, ] # works
a[a$Var1 == 1.9, ] # 0 rows

我不知道1.7和1.9有什么特别之处。这不仅发生在我的机器上。

0 个答案:

没有答案