-
Couldn't load subscription status.
- Fork 149
Import mrm traces from mzml #2199
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just one question if we could just rename the new class to PolarityTypeType.
Could be useful to have a single PolarityType data type that can be used in CompoundDBAnnotation, SpectralLibraryEntry, FeatureListRow
Can be merged like this or after rename
| import org.jetbrains.annotations.NotNull; | ||
| import org.jetbrains.annotations.Nullable; | ||
|
|
||
| public class MsChromatogramPolarityType extends DataType<PolarityType> implements NullColumnType, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could this be just PolarityType (which we also do not have yet but maybe useful in MS feature list if we ever get to merge polarities in one list)
Or is this required to be more specific by its name?
Also it could be a column that just shows + or - as text?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think for feature lists we should rely on the feature.getRepresentativeSpectrum.getPolarity, because it is directly connected to the raw data. That's why the name is so specific. For libraries we usually know what adduct it is and can rely on that.
If we want to expand this, we should add setting of the polarity in the feature data utils.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This could make sense. For the feature it could be a linked data type.
One issue is that sometimes we dont have a representative scan so this may be null.
So could be still valid to put a simple PolarityTypeType.
But we can do this once we merge across polarity
| return unit; | ||
| } | ||
|
|
||
| public static ActivationMethod fromActivationType(ActivationType type) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could annotate argument as @nullable
And could then simplify the caller and remove the null check there. But optional.
| final ActivationMethod method = activationInfo != null ? ActivationMethod.fromActivationType( | ||
| activationInfo.getActivationType()) : null; | ||
| final ActivationMethod method = ActivationMethod.fromActivationType( | ||
| activationInfo != null ? activationInfo.getActivationType() : null); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
true still required the null check, sorry thought it would make it easier but its only a little bit easier to call
No description provided.