added anomaly model to MSstatsClean call#14
Conversation
|
Caution Review failedThe pull request is closed. ℹ️ Recent review infoConfiguration used: Organization UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (6)
📝 WalkthroughWalkthroughThe PR extends the DIANN-to-MSstats preprocessing pipeline by introducing anomaly scoring parameters and annotation support, integrating MSstatsMakeAnnotation from MSstatsConvert, and propagating these new capabilities through the conversion and cleaning functions via parameter threading. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Suggested reviewers
Poem
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Motivation and Context
Integrate MSstast+ into MStatsBig DIA-NN converter.
Changes
Testing
Please describe any unit tests you added or modified to verify your changes.
Checklist Before Requesting a Review
Motivation & Context
This PR integrates MSstats+ anomaly detection capabilities into the MSstatsBig DIA-NN converter pipeline. The motivation is to enable users to leverage MSstats+ anomaly scoring features when processing DIA-NN proteomics data. The solution adds anomaly model parameters (
calculateAnomalyScoresandanomalyModelFeatures) to the data processing functions and passes them through to the underlyingMSstatsCleancall, along with improved support for annotation files.Changes
Core Functionality
R/clean_DIANN.R: Extended the public function
reduceBigDIANN()with three new optional parameters:calculateAnomalyScores(default: FALSE) — enables anomaly detection scoring in MSstats+anomalyModelFeatures(default: empty vector) — specifies features for anomaly modelannotation(default: NULL) — annotation data frame or file pathcleanDIANNChunk()helper functionMSstatsClean()call to passcalculateAnomalyScoresandanomalyModelFeaturescleanDIANNChunk()to callMSstatsMakeAnnotation()to handle annotation dataread_delim_chunked()invocation to determine delimiter (delim) dynamically based on input file type (CSV, TSV/XLS, or semicolon)R/converters.R: Modified
bigDIANNtoMSstatsFormat()to:annotationparameter (default: NULL) immediately afterinput_filein the signaturecalculateAnomalyScores,anomalyModelFeatures, andannotationto thereduceBigDIANN()callDocumentation & Dependencies
MSstatsMakeAnnotationfrom MSstatsConvert packagecalculateAnomalyScores,anomalyModelFeatures, andannotationannotationparameter to function signature and documentationUnit Tests
No unit tests were added or modified in this PR to verify the new anomaly scoring parameters. While existing tests verify annotation handling (test in
tests/testthat/test-clean_DIANN.R), there are no new tests for thecalculateAnomalyScoresandanomalyModelFeaturesfunctionality.Coding Guidelines
No violations of coding guidelines are apparent. The implementation: