Skip to content

Commit

Permalink
Small correction to function sMLE
Browse files Browse the repository at this point in the history
  • Loading branch information
alesantuz committed Jan 5, 2024
1 parent 318b5aa commit 2167103
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/sMLE.R
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ sMLE <- function(synergies, mean_period, future_pts, norm, pts, R2_threshold = 0
# can be 50 but ideally not less (in case of 200-point cycles, 100 can be a good choice)
upper_limit <- nrow(P) - future_pts
nearest_n <- FNN::get.knn(
data = P[1:(nrow(P) - future_pts), ],
data = P[1:upper_limit, ],
k = mean_period
)$nn.index

Expand Down

0 comments on commit 2167103

Please sign in to comment.