-
Notifications
You must be signed in to change notification settings - Fork 81
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update the do_detectFeatures_centWave function
o Update the do_detectFeatures_centWave function to the latest code. o Fix a bug in the [ method for xcmsRaw.
- Loading branch information
Showing
6 changed files
with
824 additions
and
681 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
############################################################ | ||
## This test file is supposed to be removed once the subsetting | ||
## of xcmsRaw objects in the findPeaks methods prior to feature | ||
## detection has been tested and is working as expected. | ||
## issue #62 | ||
library(faahKO) | ||
fs <- system.file('cdf/KO/ko15.CDF', package = "faahKO") | ||
xraw <- xcmsRaw(fs, profstep = 0) | ||
|
||
test_scanrange_centWave <- function() { | ||
## Without sub-setting | ||
res_1 <- findPeaks.centWave(xraw) | ||
res_2 <- xcms:::.findPeaks.centWave_scanrange(xraw) | ||
checkIdentical(res_1, res_2) | ||
|
||
scnr <- c(90, 345) | ||
res_1 <- findPeaks.centWave(xraw, scanrange = scnr) | ||
res_2 <- xcms:::.findPeaks.centWave_scanrange(xraw, scanrange = scnr) | ||
## checkIdentical(res_1, res_2) | ||
## Does NOT work: scalerange e.g. depends on scantime. | ||
|
||
scnr <- c(1, 400) | ||
res_1 <- findPeaks.centWave(xraw, scanrange = scnr) | ||
res_2 <- xcms:::.findPeaks.centWave_scanrange(xraw, scanrange = scnr) | ||
## checkIdentical(res_1, res_2) | ||
## Does NOT work: scalerange e.g. depends on scantime. | ||
} | ||
|
||
test_scanrange_matchedFilter <- function() { | ||
## Without sub-setting | ||
res_1 <- findPeaks.matchedFilter(xraw) | ||
res_2 <- xcms:::.findPeaks.matchedFilter_scanrange(xraw) | ||
checkIdentical(res_1, res_2) | ||
|
||
scnr <- c(90, 345) | ||
res_1 <- findPeaks.matchedFilter(xraw, scanrange = scnr) | ||
res_2 <- xcms:::.findPeaks.matchedFilter_scanrange(xraw, scanrange = scnr) | ||
## checkIdentical(res_1, res_2) | ||
## WHY?? | ||
} | ||
|
||
test_scanrange_massifquant <- function() { | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.