Running examples in ‘nonmemica-Ex.R’ failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: likebut
> ### Title: Modify a Model
> ### Aliases: likebut
> 
> ### ** Examples
> 
> # Create a working project.
> source <- system.file(package = 'nonmemica','project')
> target <- tempdir()
> target <- gsub('\\\\','/',target) # for windows
> source
[1] "/home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project"
> target
[1] "/tmp/RtmpHnJZDq"
> file.copy(source,target,recursive = TRUE)
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/data/source/dose.csv to /tmp/RtmpHnJZDq/project/data/source/dose.csv: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/data/source/pk.csv to /tmp/RtmpHnJZDq/project/data/source/pk.csv: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/data/source/dem.csv to /tmp/RtmpHnJZDq/project/data/source/dem.csv: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/data/derived/drug.csv to /tmp/RtmpHnJZDq/project/data/derived/drug.csv: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/data/derived/drug.spec to /tmp/RtmpHnJZDq/project/data/derived/drug.spec: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2005/mod.tab to /tmp/RtmpHnJZDq/project/model/2005/mod.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2005/2005.lst to /tmp/RtmpHnJZDq/project/model/2005/2005.lst: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2005/2005.xml to /tmp/RtmpHnJZDq/project/model/2005/2005.xml: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2005/mod2.tab to /tmp/RtmpHnJZDq/project/model/2005/mod2.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2005/mod.msf to /tmp/RtmpHnJZDq/project/model/2005/mod.msf: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2005/2005.ctl to /tmp/RtmpHnJZDq/project/model/2005/2005.ctl: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2004/mod.tab to /tmp/RtmpHnJZDq/project/model/2004/mod.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2004/mod2.tab to /tmp/RtmpHnJZDq/project/model/2004/mod2.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2004/mod.msf to /tmp/RtmpHnJZDq/project/model/2004/mod.msf: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2004/2004.ctl to /tmp/RtmpHnJZDq/project/model/2004/2004.ctl: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2004/2004.lst to /tmp/RtmpHnJZDq/project/model/2004/2004.lst: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2004/2004.xml to /tmp/RtmpHnJZDq/project/model/2004/2004.xml: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2002/mod.tab to /tmp/RtmpHnJZDq/project/model/2002/mod.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2002/2002.ctl to /tmp/RtmpHnJZDq/project/model/2002/2002.ctl: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2002/2002.lst to /tmp/RtmpHnJZDq/project/model/2002/2002.lst: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2002/mod2.tab to /tmp/RtmpHnJZDq/project/model/2002/mod2.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2002/mod.msf to /tmp/RtmpHnJZDq/project/model/2002/mod.msf: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2002/2002.xml to /tmp/RtmpHnJZDq/project/model/2002/2002.xml: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2001/mod.tab to /tmp/RtmpHnJZDq/project/model/2001/mod.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2001/2001.lst to /tmp/RtmpHnJZDq/project/model/2001/2001.lst: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2001/mod2.tab to /tmp/RtmpHnJZDq/project/model/2001/mod2.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2001/2001.xml to /tmp/RtmpHnJZDq/project/model/2001/2001.xml: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2001/mod.msf to /tmp/RtmpHnJZDq/project/model/2001/mod.msf: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2001/2001.ctl to /tmp/RtmpHnJZDq/project/model/2001/2001.ctl: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2006/mod.tab to /tmp/RtmpHnJZDq/project/model/2006/mod.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2006/2006.lst to /tmp/RtmpHnJZDq/project/model/2006/2006.lst: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2006/2006.xml to /tmp/RtmpHnJZDq/project/model/2006/2006.xml: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2006/mod2.tab to /tmp/RtmpHnJZDq/project/model/2006/mod2.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2006/mod.msf to /tmp/RtmpHnJZDq/project/model/2006/mod.msf: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2006/2006.ctl to /tmp/RtmpHnJZDq/project/model/2006/2006.ctl: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2007/mod.tab to /tmp/RtmpHnJZDq/project/model/2007/mod.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2007/2007.xml to /tmp/RtmpHnJZDq/project/model/2007/2007.xml: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2007/mod2.tab to /tmp/RtmpHnJZDq/project/model/2007/mod2.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2007/mod.msf to /tmp/RtmpHnJZDq/project/model/2007/mod.msf: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2007/2007.lst to /tmp/RtmpHnJZDq/project/model/2007/2007.lst: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2007/2007.ctl to /tmp/RtmpHnJZDq/project/model/2007/2007.ctl: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2003/mod.tab to /tmp/RtmpHnJZDq/project/model/2003/mod.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2003/2003.lst to /tmp/RtmpHnJZDq/project/model/2003/2003.lst: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2003/2003.ctl to /tmp/RtmpHnJZDq/project/model/2003/2003.ctl: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2003/mod2.tab to /tmp/RtmpHnJZDq/project/model/2003/mod2.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2003/2003.xml to /tmp/RtmpHnJZDq/project/model/2003/2003.xml: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/2003/mod.msf to /tmp/RtmpHnJZDq/project/model/2003/mod.msf: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/1001/1001.ctl to /tmp/RtmpHnJZDq/project/model/1001/1001.ctl: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/1001/mod.tab to /tmp/RtmpHnJZDq/project/model/1001/mod.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/1001/1001.par to /tmp/RtmpHnJZDq/project/model/1001/1001.par: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/1001/bootstrap_dir2/bootstrap_results.csv to /tmp/RtmpHnJZDq/project/model/1001/bootstrap_dir2/bootstrap_results.csv: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/1001/1001.xml to /tmp/RtmpHnJZDq/project/model/1001/1001.xml: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/1001/mod2.tab to /tmp/RtmpHnJZDq/project/model/1001/mod2.tab: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/1001/mod.msf to /tmp/RtmpHnJZDq/project/model/1001/mod.msf: Permission denied
Warning in file.copy(source, target, recursive = TRUE) :
  problem copying /home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages/nonmemica/project/model/1001/1001.lst to /tmp/RtmpHnJZDq/project/model/1001/1001.lst: Permission denied
[1] FALSE
> project <- file.path(target,'project','model')
> 
> # Point project option at working project
> options(project = project)
> library(magrittr)
> 
> # Derive models.
> 1001 %>% likebut('revised',y = 1002, overwrite=TRUE )
Warning in dir.create(target) :
  cannot create dir '/tmp/RtmpHnJZDq/project/model/1002', reason 'Permission denied'
Warning in file(file, ifelse(append, "a", "w")) :
  cannot open file '/tmp/RtmpHnJZDq/project/model/1002/1002.ctl': No such file or directory
Error in file(file, ifelse(append, "a", "w")) : 
  cannot open the connection
Calls: %>% ... <Anonymous> -> likebut -> write.model -> write -> cat -> file
Execution halted
rm: cannot remove '/tmp/RtmpHnJZDq/project/data/source/dose.csv': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/data/source/pk.csv': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/data/source/dem.csv': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/data/derived/drug.csv': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/data/derived/drug.spec': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2005/mod.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2005/2005.lst': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2005/2005.xml': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2005/mod2.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2005/mod.msf': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2005/2005.ctl': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2004/mod.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2004/mod2.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2004/mod.msf': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2004/2004.ctl': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2004/2004.lst': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2004/2004.xml': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2002/mod.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2002/2002.ctl': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2002/2002.lst': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2002/mod2.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2002/mod.msf': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2002/2002.xml': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2001/mod.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2001/2001.lst': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2001/mod2.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2001/2001.xml': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2001/mod.msf': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2001/2001.ctl': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2006/mod.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2006/2006.lst': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2006/2006.xml': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2006/mod2.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2006/mod.msf': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2006/2006.ctl': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2007/mod.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2007/2007.xml': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2007/mod2.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2007/mod.msf': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2007/2007.lst': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2007/2007.ctl': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2003/mod.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2003/2003.lst': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2003/2003.ctl': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2003/mod2.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2003/2003.xml': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/2003/mod.msf': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/1001/1001.ctl': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/1001/mod.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/1001/1001.par': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/1001/bootstrap_dir2/bootstrap_results.csv': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/1001/1001.xml': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/1001/mod2.tab': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/1001/mod.msf': Permission denied
rm: cannot remove '/tmp/RtmpHnJZDq/project/model/1001/1001.lst': Permission denied