SugiharaLab/rEDM

block_lnlp() function not found

Closed this issue · 3 comments

Hello, thanks for all the work on this package!
I have been running into some trouble with the block_lnlp function. When I last used the function about a year ago it worked fine, but now when I run the exact same scripts I get a ‘function not found’ error. There’s no such error when calling other functions from the rEDM package, and running ?block_lnlp does actually bring up the documentation. A colleague of mine had the same issue when calling the function on his machine.

Please note as detailed in the package NEWS, the legacy functions have been deprecated as of version 1.15. Please note the package documentation does not list them. Previous versions suggested to not use the legacy functions, rather the updated API from version 1.3, as they are direct calls to the cppEDM kernel. CRAN NEWS prior to version 1.15 contained:

  • It is recommended to use functions: Simplex, SMap, CCM, Embed, Multiview, EmbedDimension, PredictInterval, PredictNonlinear, ComputeError instead of the legacy version 0.7 signatures. See Version 1.3 notes.

Apologies if this causes an issue, however, it became unfeasible to maintain the legacy functions across R versions/platforms. If there is a request to add functionality, we can add it to the development list, but updates can take a while as there is only one developer.

Help on block_lnlp:

> ?block_lnlp
No documentation forblock_lnlpin specified packages and libraries:
you could try ‘??block_lnlp
> sessionInfo()
R version 4.3.0 (2023-04-21)
Platform: x86_64-pc-linux-gnu (64-bit)

Matrix products: default
BLAS:   /usr/lib/x86_64-linux-gnu/blas/libblas.so.3.10.0 
LAPACK: /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3.10.0

other attached packages:
[1] rEDM_1.15.3

loaded via a namespace (and not attached):
[1] compiler_4.3.0 tools_4.3.0    Rcpp_1.0.10   

@SoftwareLiteracy Thank you for the prompt response, I will use the Simplex function then. I do have one remaining question. Since what I'm interested in is the rho value and not so much the predictions themselves: do the new functions offer an easy way to access this rho value, like there used to be with block_lnlp (i.e. block_lnlp_output$stats$rho$rho)?

A call to the ComputeError function is designed to do this.

library( rEDM )
df = Lorenz5D
S = Simplex( dataFrame = df, E = 5, columns = 'V1', target = 'V3',
             lib = c(1,300), pred = c(501,550) )
unlist( ComputeError( S $ Observations, S $ Predictions )  )
   MAE    rho   RMSE 
2.6667 0.6485 3.1605