我想融化一個數據框,並得到這個奇怪的錯誤。任何想法爲什麼?R - 重塑 - 融化錯誤
str(zx7)
'data.frame': 519 obs. of 5 variables:
$ calday.new: Date, format: "2011-01-03" "2011-01-04" "2011-01-05" "2011-01-06" ...
$ A20 : Time-Series from 1 to 519: 0 0 0 0 0 0 0 0 0 0 ...
$ B20 : Time-Series from 1 to 519: 0 0 0 0 0 0 0 0 0 0 ...
$ C20 : Time-Series from 1 to 519: 0 0 0 0 0 0 0 0 0 0 ...
$ D20 : Time-Series from 1 to 519: 0 0 0 0 0 0 0 0 0 0 ...
zx7.melt <- melt(zx7, id=c("calday.new"))
Error in `[<-.ts`(`*tmp*`, ri, value = c(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, : only replacement of elements is allowed
@你使用哪種版本的reshape2?我無法重現錯誤。 – agstudy
@agstudy,正確的問題是「你使用了哪個版本的重塑?」看到我的迴應。 – A5C1D2H2I1M1N2O1R2T1