Running examples in ‘MonoInc-Ex.R’ failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: MonoInc
> ### Title: Monotonic Increasing
> ### Aliases: MonoInc
> ### Keywords: monotonic mono
> 
> ### ** Examples
> 
> data(simulated_data)
> simulated_data <- simulated_data[1:1000,]
> data(data.r)
> library(sitar)
Loading required package: nlme
Loading required package: splines
> 
> ## Run MonoInc
> sum <- MonoInc(simulated_data, 1,2,3, data.r,5,direction='inc', w1=0.3, min=30, max=175, 
+     impType1=NULL, impType2=NULL, sum=TRUE)
Warning: executing %dopar% sequentially: no parallel backend registered
> head(sum)
  ID   X         Y Nearest.Neighbor Regression      LOCF Last.Next
1  1  13  66.94740         66.94740   66.94740  66.94740  66.94740
2  1  27  82.41612         82.41612   82.41612  82.41612  82.41612
3  1  42  98.21975         98.21975   98.21975  98.21975  98.21975
5  1  46 100.33827        100.33827  100.33827 100.33827 100.33827
6  1  58 106.61578        106.61578  106.61578 106.61578 106.61578
8  1 117 132.88932        132.88932  132.88932 132.88932 132.88932
  Fractional.Reg Decreasing Outside.Range
1       66.94740      FALSE         FALSE
2       82.41612      FALSE         FALSE
3       98.21975      FALSE         FALSE
5      100.33827      FALSE         FALSE
6      106.61578      FALSE         FALSE
8      132.88932      FALSE         FALSE
> test <- MonoInc(simulated_data, 1,2,3, data.r,5,direction='inc', w1=0.3, min=30, max=175, 
+     impType1="nn", impType2="fr")
> head(test)
  ID  X     Nn.Fr Decreasing Outside.Range
1  1 13  66.94740      FALSE         FALSE
2  1 27  82.41612      FALSE         FALSE
3  1 42  98.21975      FALSE         FALSE
4  1 44  91.94301       TRUE         FALSE
5  1 46 100.33827      FALSE         FALSE
6  1 58 106.61578      FALSE         FALSE
> 
> ## plot longitudinal height for each id
> mplot(x=X, y=Nn.Fr, data=test)
Warning in seq_len(nrow(df)) :
  first element used of 'length.out' argument
Error in seq_len(nrow(df)) : 
  argument must be coercible to non-negative integer
Calls: mplot ... by.data.frame -> structure -> eval -> eval -> tapply
Execution halted