Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unexplained numbers turned into variables #29

Merged
merged 6 commits into from
Dec 13, 2023

Conversation

KristinaGomoryova
Copy link
Collaborator

For the IsoFiltR() function and MFAssign() functions, numbers which have not been explained in the script were either provided an explanation and linked to a dissertation thesis describing the package, or turned into variables if used repeatedly.

Based on this issue.

@KristinaGomoryova KristinaGomoryova linked an issue Dec 12, 2023 that may be closed by this pull request
Copy link

codecov bot commented Dec 12, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

❗ No coverage uploaded for pull request base (master@cdbe012). Click here to learn what that means.

Additional details and impacted files
@@           Coverage Diff            @@
##             master     #29   +/-   ##
========================================
  Coverage          ?   8.62%           
========================================
  Files             ?      10           
  Lines             ?    4093           
  Branches          ?       0           
========================================
  Hits              ?     353           
  Misses            ?    3740           
  Partials          ?       0           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@hechth hechth self-requested a review December 13, 2023 08:31
ch2_mass <- 14.01565
s34_mass <- 1.995797
ch2_mass <- 14.01565 # replaced in a code
s34_mass <- 1.995797 # replaced in a code
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does #replaced in a code mean? Which code?

Comment on lines +1 to +12
ch2_mass <- 14.01565
M_NH4 <- 18.033823 # M+NH4 (for ref. see https://fiehnlab.ucdavis.edu/staff/kind/metabolomics/ms-adduct-calculator/)
M_Na <- 22.989221 # is either this: https://www.chem.ualberta.ca/~massspec/ion_mass.pdf or should be 22.989218 based on resource above
proton <- 1.00727645216
electron <- 0.000548597
s34_isodiff <- 1.995797
o16_mass <- 15.9949146223
h2_mass <- 2.01565
h2o_mass <- 18.01056468
ch2o_mass <- 30.01056468
c13_isodiff <- 1.0033548380
c13_isodiff_double <- 2.006709676
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given all these constants and functions in the Utilities Module, I'm thinking whether it would not actually make sense to import rcdk to handle these things and to make the package more generic.

MFAssignR/R/MFAssign.R Outdated Show resolved Hide resolved
@hechth hechth merged commit d33d2ad into RECETOX:master Dec 13, 2023
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Find explanation for magic numbers in IsoFiltR module
2 participants