Hello!
I am not very familiar with R and I am using a code to estimate the environmental footprint of a pharmaceutical. I tried to follow the steps indicate on this website (Fine Chem – Safety and Environmental Technology Group | ETH Zurich). However, I get an error each time. Thanks
setwd("~/R/win-library/4.1")
install.packages("nnet")
Installing package into ‘C:/Users/mcoorema/Documents/R/win-library/4.1’
(as ‘lib’ is unspecified)
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.1/nnet_7.3-17.zip'
Content type 'application/zip' length 137610 bytes (134 KB)
downloaded 134 KB
package ‘nnet’ successfully unpacked and MD5 sums checked
The downloaded binary packages are in
C:\Users\mcoorema\AppData\Local\Temp\Rtmps9g5W7\downloaded_packages
load("~/R/win-library/4.1/Finechem/Finechem_models.RData")
source ("Finechem\Finechem_run.R")
Error in UseMethod("predict") :
no applicable method for 'predict' applied to an object of class "nnet"
System Information:
- RStudio Edition: Desktop
- RStudio Version: 2021.09.2 Build 382
- OS Version:
- R Version: x64 4.1.2