Pmetrics icon indicating copy to clipboard operation
Pmetrics copied to clipboard

Error in NPex$data$write("data.csv") after installing Pmetrics

Open Amitkolhe21 opened this issue 1 year ago • 3 comments

I'm trying to install Pmetrics but I am getting this error:

library(Pmetrics)

Welcome to Pmetrics, version 2.1.1. Use PMmanual() or visit the LAPK website at http://www.lapk.org/pmetrics.php for help. Use PM_tutorial() for an introduction. The Pmetrics forum is back! Click the tab at www.lapk.org for questions, tips and bug reports.

Follow Pmetrics tweets at https://twitter.com/USCLAPK.

CRITICAL: Execute PMbuild() in R to complete Pmetrics installation.

PMbuild() Pmetrics cannot find required compiled binary files. Pmetrics has detected gfortran and will compile required binary files. If the registration time outs, please re-run PMbuild(skipRegistration = TRUE) Pmetrics has anonymously registered your installation of this version. LAPKB does not collect or store any personal or identifying information.

Compiling 1 of 9: NPprep... Compiling 2 of 9: NPeng... Compiling 3 of 9: ITprep... Compiling 4 of 9: ITeng... Compiling 5 of 9: ITerr... Compiling 6 of 9: SIMeng... Compiling 7 of 9: DOprep... Compiling 8 of 9: DOeng... Compiling 9 of 9: mb2csv... All packages installed and permanent Fortran modules compiled.

PMtest() Error in NPex$data$write("data.csv") : attempt to apply non-function In addition: Warning message: In data(NPex, package = "Pmetrics", envir = environment()) : data set ‘NPex’ not found

Can you help me?

Amitkolhe21 avatar Jan 23 '25 18:01 Amitkolhe21

Hi @Amitkolhe21. What command are you using to install Pmetrics? This error seems to be related to the extraction of the examples into a different package

Siel avatar Jan 23 '25 18:01 Siel

@Siel I'm using the following command to install - remotes::install_github("LAPKB/Pmetrics")

Amitkolhe21 avatar Jan 23 '25 18:01 Amitkolhe21

Error in NPex$data$write("data.csv") : attempt to apply non-function In addition: Warning message: In data(NPex, package = "Pmetrics", envir = environment()) : data set ‘NPex’ not found

This is not a breaking error, and is a known (but undesired) prompt that appears during installation. Your Pmetrics installation should work just fine, as it appears that all the Fortran code has been compiled successfully.

Can you please try to run any model and see if it works? I suspect that it will.

mhovd avatar Jan 24 '25 08:01 mhovd