This command
rows <- as.numeric(system(paste("wc -l <
/path/myFile.txt",sep=""), TRUE))
works when used directly in R and when I put it inside a shell script
and submit it to the cluster.
This command
columns <- as.numeric(system(paste("head -1 < /path/myFile.txt | wc
-w",sep=""), TRUE))
works when used in R, however is not working when I submit it.
I am using these commands to count the number of rows and columns on a
large file.
Any suggestions?
Thanks,
Juliet