I couldn't install the "niftir" package.
Dear, Do you can tell me the version of R software. It took me about a week to install it, but I still couldn't install the "niftir" package in Win and Ubuntu. Thank you.
devtools::install_github("czarrar/niftir") # https://github.com/czarrar/niftir Downloading GitHub repo czarrar/niftir@master √ checking for file 'C:\Users\SJYX-CJ\AppData\Local\Temp\RtmpEF1YAP\remotes23e42706519b\czarrar-niftir-afd7905/DESCRIPTION' (759ms)
- preparing 'niftir': √ checking DESCRIPTION meta-information ...
- cleaning src
- running 'cleanup.win' Warning: C:/Users/SJYX-CJ/AppData/Local/Temp/RtmpyaMctM/Rbuild535026a614e0/niftir/man/nifti.Rd:7: unknown macro '\n' Warning: C:/Users/SJYX-CJ/AppData/Local/Temp/RtmpyaMctM/Rbuild535026a614e0/niftir/man/nifti.Rd:8: unknown macro '\n' Warning: C:/Users/SJYX-CJ/AppData/Local/Temp/RtmpyaMctM/Rbuild535026a614e0/niftir/man/nifti.Rd:35: unknown macro '\n' Warning: C:/Users/SJYX-CJ/AppData/Local/Temp/RtmpyaMctM/Rbuild535026a614e0/niftir/man/nifti.Rd:49: unexpected '}'
- checking for LF line-endings in source and make files and shell scripts
- checking for empty or unneeded directories
- looking to see if a 'data/datalist' file should be added
- building 'niftir_0.2.tar.gz' Warning: file 'niftir/cleanup' did not have execute permissions: corrected Warning: file 'niftir/configure' did not have execute permissions: corrected
Installing package into ‘C:/Users/SJYX-CJ/Documents/R/win-library/3.5’ (as ‘lib’ is unspecified)
-
installing source package 'niftir' ...
WARNING: this package has a configure script It probably needs manual configuration
** libs C:/RBuildTools/3.5/mingw_64/bin/gcc -m64 -I"C:/PROGRA~1/MICROS~2/ROPEN~1/R-35~1.3/include" -DNDEBUG -I"C:/Users/SJYX-CJ/Documents/R/win-library/3.5/Rcpp/include" -I"C:/Users/SJYX-CJ/Documents/R/win-library/3.5/BH/include" -I"C:/Users/SJYX-CJ/Documents/R/win-library/3.5/bigmemory/include" -I"C:/a/w/1/s/vendor/extsoft/include" -O2 -Wall -std=gnu99 -mtune=core2 -c nifti1_io.c -o nifti1_io.o nifti1_io.c:3:73: fatal error: niftir/nifti1_io.h: No such file or directory #include "niftir/nifti1_io.h" /* typedefs, prototypes, macros, etc. */ ^ compilation terminated. make: *** [C:/PROGRA~1/MICROS~2/ROPEN~1/R-35~1.3/etc/x64/Makeconf:208: nifti1_io.o] Error 1 ERROR: compilation failed for package 'niftir'
- removing 'C:/Users/SJYX-CJ/Documents/R/win-library/3.5/niftir' In R CMD INSTALL Error in i.p(...) : (converted from warning) installation of package ‘C:/Users/SJYX-CJ/AppData/Local/Temp/RtmpEF1YAP/file23e438556d64/niftir_0.2.tar.gz’ had non-zero exit status
run("git clone https://github.com/czarrar/connectir.git") # https://github.com/czarrar/connectir Error in run("git clone https://github.com/czarrar/connectir.git") : could not find function "run" run("R CMD INSTALL connectir") Error in run("R CMD INSTALL connectir") : could not find function "run" cat("\nCopying scripts for connectir\n")
Copying scripts for connectir
bindir <- dirname(system("which R", intern=TRUE)) Error in system("which R", intern = TRUE) : 'which' not found system(sprintf("cp connectir/inst/scripts/.R %s/", bindir)) Error in sprintf("cp connectir/inst/scripts/.R %s/", bindir) : object 'bindir' not found system(sprintf("rm -f %s/_worker.R", bindir)) Error in sprintf("rm -f %s/_worker.R", bindir) : object 'bindir' not found system(sprintf("chmod +x %s/.R", bindir)) Error in sprintf("chmod +x %s/.R", bindir) : object 'bindir' not found setwd(basedir) Error in setwd(basedir) : object 'basedir' not found run("rm -rf connectir") Error in run("rm -rf connectir") : could not find function "run"
TODO: add copying of scripts to some bin location
install.packages("niftir", repos="http://R-Forge.R-project.org") Installing package into ‘C:/Users/SJYX-CJ/Documents/R/win-library/3.5’ (as ‘lib’ is unspecified) Warning in install.packages : package ‘niftir’ is not available (for R version 3.5.3) devtools::install_github("E:\mysoftware\myCWAS_paper_Code\niftir_0.2.tar.gz") Error in parse_repo_spec(repo) : Invalid git repo specification: 'E:\mysoftware\myCWAS_paper_Code\niftir_0.2.tar.gz' install.packages("E:\mysoftware\myCWAS_paper_Code\niftir_0.2.tar.gz") Installing package into ‘C:/Users/SJYX-CJ/Documents/R/win-library/3.5’ (as ‘lib’ is unspecified) Warning in install.packages : package ‘E:\mysoftware\myCWAS_paper_Code\niftir_0.2.tar.gz’ is not available (for R version 3.5.3)
Sorry I am no longer actively maintaining this package hence the issues. People have been able to get it working with older versions of R and some other packages. (I don't think this will work on Windows but should work on Ubuntu). You can try with Rcpp version 0.12.8 and bigmemory 4.4.6. After that you might need to set dep=F so that newer versions of those tools don't install.
You can also find a python version of the package in CPAC: https://fcp-indi.github.io/docs/user/install.html and that is actively maintained.
If you are not doing any intense computation (e.g., using parcellations instead of voxels), then I've attached a pure R version of MDMR. See Rmdmr/242_parcellate_sm/20_mdmr.R for sample usage. Let me know if you have any questions on that. Rmdmr.zip
Thank you, Prof. Shehzad.
You mean I can run the connectir in a python version of the package in CPAC?
In the website, https://fcp-indi.github.io/docs/user/install.html, I didn't find how runs the connectir package.
I want to analyze the CWAS.
Do the CPAC run the CWAS?
Thank you very much. Bests, Jiu
If you have any questions, please don't hesitate to contact me.
Best!
Yours,
Jiu Chen
E-mail: [email protected] Tel: 86-187-5199-7338
From:Zarrar Shehzad [email protected] Sent At:2019 Jun. 25 (Tue.) 22:32 To:czarrar/connectir [email protected] Cc:ericchenjiu [email protected]; Author [email protected] Subject:Re: [czarrar/connectir] I couldn't install the "niftir" package. (#10)
Sorry I am no longer actively maintaining this package hence the issues. People have been able to get it working with older versions of R and some other packages. (I don't think this will work on Windows but should work on Ubuntu). You can try with Rcpp version 0.12.8 and bigmemory 4.4.6. After that you might need to set dep=F so that newer versions of those tools don't install. You can also find a python version of the package in CPAC: https://fcp-indi.github.io/docs/user/install.html and that is actively maintained. If you are not doing any intense computation (e.g., using parcellations instead of voxels), then I've attached a pure R version of MDMR. See Rmdmr/242_parcellate_sm/20_mdmr.R for sample usage. Let me know if you have any questions on that. Rmdmr.zip — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.