Skip to content

Commit b5a9b20

Browse files
committed
more fixing
1 parent 329669c commit b5a9b20

6 files changed

Lines changed: 14 additions & 17 deletions

File tree

.github/workflows/check-bioc.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,9 +187,10 @@ jobs:
187187
cd preprocessCore
188188
R CMD INSTALL --configure-args="--disable-threading" .
189189
190-
- name: Install latest PSMatch from github
190+
- name: Install latest PSMatch and PTMods from github
191191
run: |
192192
BiocManager::install("RforMassSpectrometry/PSMatch", ask = FALSE, force = TRUE)
193+
BiocManager::install("RforMassSpectrometry/PTMods", ask = FALSE, force = TRUE)
193194
continue-on-error: true
194195
shell: Rscript {0}
195196

DESCRIPTION

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ Depends:
8080
Imports:
8181
MsCoreUtils,
8282
PSMatch (>= 1.15.3),
83+
PTMods (>= 0.99.5),
8384
BiocParallel,
8485
IRanges (>= 2.13.28),
8586
plyr,

NAMESPACE

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ importFrom(PSMatch,
2121
getAminoAcids,
2222
defaultNeutralLoss)
2323

24+
importFrom(PTMods, convertAnnotation)
25+
2426
importFrom(MsCoreUtils, closest, rbindFill,
2527
impute_matrix, normalize_matrix,
2628
robustSummary, medianPolish,

R/functions-Spectrum2.R

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
calculateFragments_Spectrum2 <- function(sequence, object, tolerance=0.1,
1313
method=c("highest", "closest", "all"),
1414
relative=FALSE, ...) {
15-
1615
isValidSequence <- !missing(sequence) && !is.na(sequence) &&
1716
nchar(sequence)
1817
isValidSpectrum <- is(object, "Spectrum2") && peaksCount(object)

R/plotting-Spectrum.R

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -121,13 +121,13 @@ plotSpectrumVsSpectrum <- function(spectra, tolerance=25e-6,
121121
modifications = c(C = 57.02146),
122122
neutralLoss = defaultNeutralLoss(),
123123
z = 1,
124-
fragments = calculateFragments_Spectrum2(object,
125-
sequence = sequence, tolerance = tolerance,
126-
relative = relative, type = type, z = z,
127-
fixed_modifications = modifications,
128-
neutralLoss = neutralLoss,
129-
verbose = isMSnbaseVerbose()) |>
130-
suppressWarnings(),
124+
fragments = suppressWarnings(
125+
calculateFragments_Spectrum2(object,
126+
sequence = sequence, tolerance = tolerance,
127+
relative = relative, type = type, z = z,
128+
fixed_modifications = modifications,
129+
neutralLoss = neutralLoss,
130+
verbose = isMSnbaseVerbose())),
131131
fragments.cex = 0.75, peaks.lwd = 1, peaks.cex = 0.5, ...) {
132132
if (peaksCount(object) > 0 && !centroided(object)) {
133133
message("Your spectrum is not centroided.")

man/calculateFragments-methods.Rd

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@
8686
\examples{
8787
## find path to a mzXML file
8888
file <- dir(system.file(package = "MSnbase", dir = "extdata"),
89-
full.name = TRUE, pattern = "mzXML$")
89+
full.names = TRUE, pattern = "mzXML$")
9090

9191
## create basic MSnExp
9292
msexp <- readMSData(file, centroided = FALSE)
@@ -95,13 +95,7 @@ msexp <- readMSData(file, centroided = FALSE)
9595
msexp <- pickPeaks(msexp)
9696

9797
## calculate fragments for ACE with default modification
98-
calculateFragments("ACE", modifications=c(C=57.02146))
99-
100-
## calculate fragments for ACE with an addition N-terminal modification
101-
calculateFragments("ACE", modifications=c(C=57.02146, Nterm=229.1629))
102-
103-
## calculate fragments for ACE without any modifications
104-
calculateFragments("ACE", modifications=NULL)
98+
calculateFragments("ACE")
10599

106100
calculateFragments("VESITARHGEVLQLRPK",
107101
type=c("a", "b", "c", "x", "y", "z"),

0 commit comments

Comments
 (0)