R - argument is of length zero in if statement

后端 未结 6 1735
别那么骄傲
别那么骄傲 2020-11-28 07:39

I am having a little problem with R and I am not sure why. It is telling me that this line: if(temp > data[[k]][[k2]]) { is of argument length 0. Here is the

6条回答
  •  感情败类
    2020-11-28 07:47

    The simplest solution to the problem is to change your for loop statement :

    Instead of using

          for (i in **0**:n))
    

    Use

          for (i in **1**:n))
    

提交回复
热议问题