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
Added new SkylineCmd arguments for building ion mobility libraries: -… #2301
Changes from 1 commit
2c71cff
3721ec9
34e4936
4aa851f
cb68a1a
cc1ffc0
9348883
d96b2fb
ac1419c
a2d2824
346e5a3
54213ee
0555062
5e4175e
b8af30c
e0d1032
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -215,6 +215,17 @@ public bool Saving | |
public string SharedFile { get; private set; } | ||
public ShareType SharedFileType { get; private set; } | ||
|
||
// For creating a .imsdb ion mobility library | ||
public static readonly Argument ARG_CREATE_IMSDB = new DocArgument(@"ionmobility-create-library", PATH_TO_FILE, | ||
bspratt marked this conversation as resolved.
Show resolved
Hide resolved
|
||
(c, p) => c.CreateIMSDB(p)); | ||
bspratt marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
// For creating a .imsdb ion mobility library | ||
public static readonly Argument ARG_CREATE_IMSDB_NAME = new DocArgument(@"ionmobility-create-library-name", NAME_VALUE, | ||
(c, p) => c.IMSDbName = p.Value); | ||
|
||
private static readonly ArgumentGroup GROUP_CREATE_IMSDB = new ArgumentGroup(() => CommandArgUsage.CommandArgs_GROUP_CREATE_IMSDB_Ion_Mobility_Library, false, | ||
brendanx67 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
ARG_CREATE_IMSDB, ARG_CREATE_IMSDB_NAME); | ||
|
||
public static readonly Argument ARG_IMPORT_FILE = new DocArgument(@"import-file", PATH_TO_FILE, | ||
(c, p) => c.ParseImportFile(p)); | ||
public static readonly Argument ARG_IMPORT_REPLICATE_NAME = new DocArgument(@"import-replicate-name", NAME_VALUE, | ||
|
@@ -337,6 +348,8 @@ private bool ValidateMinimizeResultsArgs() | |
return true; | ||
} | ||
|
||
public MsDataFileUri IMSDbFile { get; private set; } | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Too many capitals in the naming. Use ImsDb or Imsdb instead, like MsDataFile. We prefer title-case even for acronyms. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Right, will fix |
||
public string IMSDbName { get; private set; } | ||
|
||
public List<MsDataFileUri> ReplicateFile { get; private set; } | ||
public string ReplicateName { get; private set; } | ||
|
@@ -362,6 +375,11 @@ private bool ValidateMinimizeResultsArgs() | |
public double? LockmassTolerance { get; private set; } | ||
public LockMassParameters LockMassParameters { get { return new LockMassParameters(LockmassPositive, LockmassNegative, LockmassTolerance); } } | ||
|
||
private void CreateIMSDB(NameValuePair pair) | ||
{ | ||
IMSDbFile = new MsDataFilePath(pair.ValueFullPath); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is not an MsDataFile so strange to be using MsDataFilePath. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yup, I'll fix that, thanks. |
||
} | ||
|
||
private void ParseImportFile(NameValuePair pair) | ||
{ | ||
ReplicateFile.Add(new MsDataFilePath(pair.ValueFullPath)); | ||
|
@@ -556,6 +574,10 @@ public bool AddDecoys | |
{ | ||
get { return !string.IsNullOrEmpty(AddDecoysType); } | ||
} | ||
public bool CreatingIMSDB | ||
{ | ||
get { return IMSDbFile != null; } | ||
} | ||
public bool ImportingResults | ||
{ | ||
get { return ImportingReplicateFile || ImportingSourceDirectory; } | ||
|
@@ -1784,6 +1806,7 @@ public static IEnumerable<IUsageBlock> UsageBlocks | |
GROUP_IMPORT_SEARCH, | ||
GROUP_IMPORT_LIST, | ||
GROUP_ADD_LIBRARY, | ||
GROUP_CREATE_IMSDB, | ||
GROUP_DECOYS, | ||
GROUP_REFINEMENT, | ||
GROUP_REFINEMENT_W_RESULTS, | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
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.
What about adding to an existing IMSDB? Seems like that should also be possible.
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.
Agreed, that just wasn't the immediate requirement. If you agree I'll just open an issue for that and return my attention to Feature Finding.
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 it is at least worth thinking through now how you would support that within the command argument group you have created. Maybe making this title something more generic like:
Ion mobility library support
And arguments maybe:
--ionmobility-library-add=path/to/file.imsdb
--ionmobility-library-create=path/to/file.imsdb
--ionmobility-library-name=name
And eventually:
--ionmobility-library-addresults
create assumes addresults, obviously. Though, a user might use the combination:
--ionmobility-library-add=path/to/file.imsdb --ionmobility-library-name=name --ionmobility-library-addresults
which might ultimately be what Scripps wants to do to create a single .imsdb with all of their compounds in it for sharing with other Skyline users.
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.
Agreed, the hierarchy should be --ionmobility-library-XXX rather than --ionmobility-create-XXX for best extensibility.
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.