简体   繁体   中英

How do you run an R file on ubuntu?

I tried to run an Rscript file from my ubuntu terminal on the server using the code:

Rscript etl/ConceptTables/loadTables.R mimiciii"

The file is located in stated directory below but I need to run the script from the root directory. However, it is saying this file does not exist but it clearly does. I also tried running this by entering the R environment first but instead, I get:

"Error: Unexpected symbol in "etl/ConceptTables/loadTables.R mimiciii"

I am following instructions from this mimic-omoop ETL on github here: https://github.com/chichukw/mimic-omop/blob/master/README-run-etl.md and I already created the cpg file with my username and database name. Could anyone clarify what I am doing wrong?

Try using the full path of the file. The error you have posted is "Unexpected symbol"

Could be because you have added a double quote at the end of mimiciii. Or is it a mistake while posting the question?

If you are using double quotes for the path, ensure that it is " and not “.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM