Fix RScript input

This commit is contained in:
2024-08-04 23:01:10 -04:00
parent 0715c2b150
commit 4059cc965f
7 changed files with 21 additions and 23 deletions

View File

@@ -26,28 +26,28 @@ args <- commandArgs(TRUE)
inputFile <- args[1]
# Set output dir
if (length(args) > 2) {
if (length(args) >= 2) {
outDir <- args[2]
} else {
outDir <- "/ZScores/" # for legacy workflow
}
# Set StudyInfo file path
if (length(args) > 3) {
if (length(args) >= 3) {
studyInfo <- args[3]
} else {
studyInfo <- "../Code/StudyInfo.csv" # for legacy workflow
}
# Set SGDgeneList file path
if (length(args) > 4) {
if (length(args) >= 4) {
SGDgeneList <- args[4]
} else {
SGDgeneList <- "../Code/SGD_features.tab" # for legacy workflow
}
# Set standard deviation
if (length(args) > 5) {
if (length(args) >= 5) {
delBGFactor <- args[5]
} else {
# User prompt for std multiplier Value
@@ -78,11 +78,9 @@ expNumber <- as.numeric(sub("^.*?(\\d+)$", "\\1", getwd()))
Labels[expNumber,3] <- delBGFactor
write.csv(Labels,file=studyInfo,row.names = FALSE)
###############################################################################
################### BEGIN USER DATA SELECTION SECTION #########################
###############################################################################
# BEGIN USER DATA SELECTION SECTION
#read in the data
# Read in the data
X <- read.delim(inputFile,skip=2,as.is=T,row.names=1,strip.white=TRUE)
X <- X[!(X[[1]]%in%c("","Scan")),]
#X <- X[!(X[[1]]%in%c(61:76)),] #Remove dAmp plates which are Scans 61 thru 76