Package: tsfknn 0.6.0

tsfknn: Time Series Forecasting Using Nearest Neighbors

Allows forecasting time series using nearest neighbors regression Francisco Martinez, Maria P. Frias, Maria D. Perez-Godoy and Antonio J. Rivera (2019) <doi:10.1007/s10462-017-9593-z>. When the forecasting horizon is higher than 1, two multi-step ahead forecasting strategies can be used. The model built is autoregressive, that is, it is only based on the observations of the time series. The nearest neighbors used in a prediction can be consulted and plotted.

Authors:Francisco Martinez [aut, cre]

tsfknn_0.6.0.tar.gz
tsfknn_0.6.0.zip(r-4.7)tsfknn_0.6.0.zip(r-4.6)tsfknn_0.6.0.zip(r-4.5)
tsfknn_0.6.0.tgz(r-4.6-x86_64)tsfknn_0.6.0.tgz(r-4.6-arm64)tsfknn_0.6.0.tgz(r-4.5-x86_64)tsfknn_0.6.0.tgz(r-4.5-arm64)
tsfknn_0.6.0.tar.gz(r-4.7-arm64)tsfknn_0.6.0.tar.gz(r-4.7-x86_64)tsfknn_0.6.0.tar.gz(r-4.6-arm64)tsfknn_0.6.0.tar.gz(r-4.6-x86_64)
tsfknn_0.6.0.tgz(r-4.6-emscripten)
manual.pdf |manual.html
card.svg |card.png
tsfknn/json (API)
NEWS

# Install 'tsfknn' in R:
install.packages('tsfknn', repos = c('https://franciscomartinezdelrio.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/franciscomartinezdelrio/tsfknn/issues

Uses libs:
  • c++– GNU Standard C++ Library v3

On CRAN:

Conda:

cpp

5.56 score 11 stars 66 scripts 401 downloads 5 exports 18 dependencies

Last updated from:45e95c28ac. Checks:13 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-arm64OK150
linux-devel-x86_64OK148
source / vignettesOK182
linux-release-arm64OK129
linux-release-x86_64OK138
macos-release-arm64OK85
macos-release-x86_64OK426
macos-oldrel-arm64OK109
macos-oldrel-x86_64OK206
windows-develOK153
windows-releaseOK114
windows-oldrelOK152
wasm-releaseOK115

Exports:knn_examplesknn_forecastingn_training_examplesnearest_neighborsrolling_origin

Dependencies:clicpp11farverggplot2gluegtableisobandlabelinglifecycleR6RColorBrewerRcpprlangS7scalesvctrsviridisLitewithr

Time Series Forecasting with KNN in R: the tsfknn Package

Rendered fromtsfknn.Rmdusingknitr::rmarkdownon May 05 2026.

Last update: 2023-12-20
Started: 2018-03-21