FernandaDiaz12 / pediatric_astrocytoma

Repository for the analysis of pediatric astrocytoma.
0 stars 3 forks source link

Avoid absolute paths or clearly document them #9

Open AliciaMstt opened 5 years ago

AliciaMstt commented 5 years ago

Your R scripts (in 7.edgeR) contain lines like these:

setwd("~/Documents/Maestria/Taller_Bioinfo/pediatric_astrocytoma")

C <- (read.csv("~/Documents/FernandaRNA/pediatric_astrocytoma/DEControl-I.csv", header = TRUE))

Please notice that this will prevent your script from running in any computer. To avoid this, I would recommend writing your script assuming its working directory will be 7.edgeR, which is the default (ie if you open R by clicking on the script, R will automatically set the working directory to 7.edgeR). Therefore you can use relative paths from 7.edgeR to wherever is the data you want to read or write.

FernandaDiaz12 commented 5 years ago

Hi, Alicia. I changed all the absolute paths, to relative paths. All of them are considering you are in the /bin/.

write.csv(qlfC$table, "../data/DEControl-I.csv")

AliciaMstt commented 5 years ago

You still have some absolute paths in other scripts, for instance in 4. AlignmentQC.sh:

clipping_profile.py -i ~/Documents/FernandaRNA/SAM_STAR_files/$samp_name -s "PE" -o data/clip/$samp_name

Watch out for this