Mercurial > repos > lecorguille > xcms_fillpeaks
comparison xcms_fillpeaks.r @ 44:1b5fb5a27f5e draft
"planemo upload for repository https://github.com/workflow4metabolomics/xcms commit f1caf2a3bf23cf319a75dd12c86402555dd02617"
| author | workflow4metabolomics |
|---|---|
| date | Wed, 12 Feb 2020 13:25:04 +0000 |
| parents | eeade1310758 |
| children | 1a711c1b8b1f |
comparison
equal
deleted
inserted
replaced
| 43:eeade1310758 | 44:1b5fb5a27f5e |
|---|---|
| 51 if (!hasFeatures(xdata)) stop("You must always do a group step after a retcor. Otherwise it won't work for the fillpeaks step") | 51 if (!hasFeatures(xdata)) stop("You must always do a group step after a retcor. Otherwise it won't work for the fillpeaks step") |
| 52 | 52 |
| 53 # Handle infiles | 53 # Handle infiles |
| 54 if (!exists("singlefile")) singlefile <- NULL | 54 if (!exists("singlefile")) singlefile <- NULL |
| 55 if (!exists("zipfile")) zipfile <- NULL | 55 if (!exists("zipfile")) zipfile <- NULL |
| 56 rawFilePath <- getRawfilePathFromArguments(singlefile, zipfile, args) | 56 rawFilePath <- retrieveRawfileInTheWorkingDirectory(singlefile, zipfile, args) |
| 57 zipfile <- rawFilePath$zipfile | 57 zipfile <- rawFilePath$zipfile |
| 58 singlefile <- rawFilePath$singlefile | 58 singlefile <- rawFilePath$singlefile |
| 59 directory <- retrieveRawfileInTheWorkingDirectory(singlefile, zipfile) | |
| 60 | |
| 61 # Check some character issues | |
| 62 md5sumList <- list("origin" = getMd5sum(directory)) | |
| 63 checkXmlStructure(directory) | |
| 64 checkFilesCompatibilityWithXcms(directory) | |
| 65 | 59 |
| 66 | 60 |
| 67 cat("\n\n") | 61 cat("\n\n") |
| 68 | 62 |
| 69 # ----- MAIN PROCESSING INFO ----- | 63 # ----- MAIN PROCESSING INFO ----- |
| 79 fillChromPeaksParam <- do.call(paste0(method,"Param"), args) | 73 fillChromPeaksParam <- do.call(paste0(method,"Param"), args) |
| 80 print(fillChromPeaksParam) | 74 print(fillChromPeaksParam) |
| 81 | 75 |
| 82 # back compatibility between xcms-3.0.0 and xcms-3.5.2 | 76 # back compatibility between xcms-3.0.0 and xcms-3.5.2 |
| 83 xdata <- updateObject(xdata) | 77 xdata <- updateObject(xdata) |
| 84 | 78 register(SerialParam()) |
| 85 xdata <- fillChromPeaks(xdata, param=fillChromPeaksParam) | 79 xdata <- fillChromPeaks(xdata, param=fillChromPeaksParam) |
| 86 | 80 |
| 87 if (exists("intval")) { | 81 if (exists("intval")) { |
| 88 getPeaklistW4M(xdata, intval, convertRTMinute, numDigitsMZ, numDigitsRT, naTOzero, "variableMetadata.tsv", "dataMatrix.tsv") | 82 getPeaklistW4M(xdata, intval, convertRTMinute, numDigitsMZ, numDigitsRT, naTOzero, "variableMetadata.tsv", "dataMatrix.tsv") |
| 89 } | 83 } |
