mspire 0.10.7 → 0.10.7.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: fbffabefff9915adb341c9e9ed2f21212db4ed6b
4
- data.tar.gz: b259fb13ecb08e7fe766cc0ee790b96cce806047
3
+ metadata.gz: eb806c3b3fc8c31258494541f15be3064f9e8a15
4
+ data.tar.gz: 9666168614b20a6a8ac974c5c6cd29c715b87b3e
5
5
  SHA512:
6
- metadata.gz: bbdb120988547420fd69b3592120965f01ec23881478f1557709667869f9848710efb0bd9e39e935319c0943a33b9f5ea4d94feef5c102d0068a131ed584671e
7
- data.tar.gz: 3ebdd7b90213521fc444d3ab07a60580ad6dfc095c781e6e64f3131bb0fb4bbe745f62216336443340c776d71dede8ab1ae4812522ac853a50b897578c1cbd13
6
+ metadata.gz: f8d798ed8a3efd8b0483c4b957b139eb4a040b76f598eecc9615cfe8332d8bdfbd0b66185e3416d5e98e57fc8f8705af44e479a3d7e263f2c90d138cd0098223
7
+ data.tar.gz: db2e325aef76a22747cca13f5a25e9357b1e76c1a253ef9b71a10fae7b7df6fd8f1faded2c1f5352112a37ab65e54fe3df6099e1c7b717a4e89b70db80f70075
@@ -26,6 +26,21 @@ module Mspire
26
26
  yield(self) if block_given?
27
27
  end
28
28
 
29
+ # returns the first existing scan window, or nil if none
30
+ def scan_window
31
+ return nil unless scan_windows
32
+ scan_windows.first
33
+ end
34
+
35
+ # returns a doublet: the upper and lower scan window limits as floats.
36
+ # Returns an array of two values, but may be nil if they don't exist.
37
+ def scan_window_limits
38
+ %w(MS:1000501 MS:1000500).map do |acc|
39
+ val = scan_window.fetch_by_acc(acc)
40
+ val && val.to_f
41
+ end
42
+ end
43
+
29
44
  # link should have:
30
45
  #
31
46
  # :ref_hash
@@ -87,6 +87,12 @@ module Mspire
87
87
  end
88
88
  end
89
89
 
90
+ # returns the first scan from the scan_list, or nil if none are found
91
+ def scan
92
+ return nil unless scan_list
93
+ scan_list.first
94
+ end
95
+
90
96
  # returns the ms_level as an Integer
91
97
  def ms_level
92
98
  fetch_by_acc('MS:1000511')
@@ -1,3 +1,3 @@
1
1
  module Mspire
2
- VERSION = "0.10.7"
2
+ VERSION = "0.10.7.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mspire
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.7
4
+ version: 0.10.7.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - John T. Prince
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-03-07 00:00:00.000000000 Z
12
+ date: 2014-03-21 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: nokogiri
@@ -460,7 +460,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
460
460
  version: '0'
461
461
  requirements: []
462
462
  rubyforge_project:
463
- rubygems_version: 2.2.0
463
+ rubygems_version: 2.2.2
464
464
  signing_key:
465
465
  specification_version: 4
466
466
  summary: mass spectrometry proteomics, lipidomics, and tools