cartesian 0.5.0 → 0.5.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (49) hide show
  1. data/History.txt +8 -1
  2. data/Manifest.txt +42 -0
  3. data/README.rdoc +3 -6
  4. data/lib/cartesian.rb +11 -9
  5. data/lib/cartesian/version.rb +7 -1
  6. data/lib/recursive.rb +2 -0
  7. data/script/txt2html +82 -0
  8. data/website/doc/classes/Array.html +128 -0
  9. data/website/doc/classes/Cartesian.html +398 -0
  10. data/website/doc/classes/Cartesian.src/M000020.html +18 -0
  11. data/website/doc/classes/Cartesian.src/M000021.html +18 -0
  12. data/website/doc/classes/Cartesian.src/M000022.html +18 -0
  13. data/website/doc/classes/Cartesian.src/M000023.html +23 -0
  14. data/website/doc/classes/Cartesian.src/M000026.html +23 -0
  15. data/website/doc/classes/Cartesian.src/M000027.html +30 -0
  16. data/website/doc/classes/CartesianIterator.html +326 -0
  17. data/website/doc/classes/CartesianIterator.src/M000001.html +21 -0
  18. data/website/doc/classes/CartesianIterator.src/M000002.html +18 -0
  19. data/website/doc/classes/CartesianIterator.src/M000003.html +21 -0
  20. data/website/doc/classes/CartesianIterator.src/M000005.html +20 -0
  21. data/website/doc/classes/CartesianIterator.src/M000008.html +20 -0
  22. data/website/doc/classes/CartesianIterator.src/M000009.html +19 -0
  23. data/website/doc/classes/CartesianIterator.src/M000012.html +19 -0
  24. data/website/doc/classes/CartesianIterator.src/M000013.html +39 -0
  25. data/website/doc/classes/Enumerable.html +112 -0
  26. data/website/doc/classes/GridSearch.html +160 -0
  27. data/website/doc/classes/GridSearch.src/M000014.html +18 -0
  28. data/website/doc/classes/GridSearch.src/M000015.html +18 -0
  29. data/website/doc/classes/Iterable.html +176 -0
  30. data/website/doc/classes/Iterable.src/M000016.html +19 -0
  31. data/website/doc/classes/Iterable.src/M000017.html +19 -0
  32. data/website/doc/classes/Iterable.src/M000018.html +18 -0
  33. data/website/doc/classes/Iterable.src/M000019.html +18 -0
  34. data/website/doc/classes/Range.html +118 -0
  35. data/website/doc/created.rid +1 -0
  36. data/website/doc/files/cartesian_iterator_rb.html +101 -0
  37. data/website/doc/files/cartesian_rb.html +108 -0
  38. data/website/doc/files/grid_search_rb.html +101 -0
  39. data/website/doc/fr_class_index.html +33 -0
  40. data/website/doc/fr_file_index.html +29 -0
  41. data/website/doc/fr_method_index.html +54 -0
  42. data/website/doc/index.html +24 -0
  43. data/website/doc/rdoc-style.css +208 -0
  44. data/website/index.html +110 -0
  45. data/website/index.txt +96 -0
  46. data/website/javascripts/rounded_corners_lite.inc.js +285 -0
  47. data/website/stylesheets/screen.css +138 -0
  48. data/website/template.html.erb +48 -0
  49. metadata +48 -5
@@ -0,0 +1,21 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html>
7
+ <head>
8
+ <title>new (CartesianIterator)</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
11
+ </head>
12
+ <body class="standalone-code">
13
+ <pre><span class="ruby-comment cmt"># File cartesian_iterator.rb, line 3</span>
14
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">foo</span>, <span class="ruby-identifier">bar</span>)
15
+ <span class="ruby-ivar">@lists</span> = []
16
+ <span class="ruby-ivar">@tot_iter</span> = <span class="ruby-value">1</span>
17
+ <span class="ruby-identifier">product!</span>(<span class="ruby-identifier">foo</span>)
18
+ <span class="ruby-identifier">product!</span>(<span class="ruby-identifier">bar</span>)
19
+ <span class="ruby-keyword kw">end</span></pre>
20
+ </body>
21
+ </html>
@@ -0,0 +1,18 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html>
7
+ <head>
8
+ <title>dup (CartesianIterator)</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
11
+ </head>
12
+ <body class="standalone-code">
13
+ <pre><span class="ruby-comment cmt"># File cartesian_iterator.rb, line 10</span>
14
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">dup</span>
15
+ <span class="ruby-constant">Marshal</span>.<span class="ruby-identifier">load</span>(<span class="ruby-constant">Marshal</span>.<span class="ruby-identifier">dump</span>(<span class="ruby-keyword kw">self</span>))
16
+ <span class="ruby-keyword kw">end</span></pre>
17
+ </body>
18
+ </html>
@@ -0,0 +1,21 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html>
7
+ <head>
8
+ <title>equal (CartesianIterator)</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
11
+ </head>
12
+ <body class="standalone-code">
13
+ <pre><span class="ruby-comment cmt"># File cartesian_iterator.rb, line 14</span>
14
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">equal</span>(<span class="ruby-identifier">other</span>)
15
+ <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">instance_variables</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">var_name</span><span class="ruby-operator">|</span>
16
+ <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">false</span> <span class="ruby-keyword kw">if</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">instance_variable_get</span>(<span class="ruby-identifier">var_name</span>) <span class="ruby-operator">!=</span> <span class="ruby-identifier">other</span>.<span class="ruby-identifier">instance_variable_get</span>(<span class="ruby-identifier">var_name</span>)
17
+ <span class="ruby-keyword kw">end</span>
18
+ <span class="ruby-keyword kw">true</span>
19
+ <span class="ruby-keyword kw">end</span></pre>
20
+ </body>
21
+ </html>
@@ -0,0 +1,20 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html>
7
+ <head>
8
+ <title>product! (CartesianIterator)</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
11
+ </head>
12
+ <body class="standalone-code">
13
+ <pre><span class="ruby-comment cmt"># File cartesian_iterator.rb, line 22</span>
14
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">product!</span>(<span class="ruby-identifier">other</span>)
15
+ <span class="ruby-ivar">@lists</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">other</span>.<span class="ruby-identifier">to_a</span>.<span class="ruby-identifier">dup</span>
16
+ <span class="ruby-ivar">@tot_iter</span> <span class="ruby-operator">*=</span> <span class="ruby-ivar">@lists</span>[<span class="ruby-value">-1</span>].<span class="ruby-identifier">size</span>
17
+ <span class="ruby-keyword kw">self</span>
18
+ <span class="ruby-keyword kw">end</span></pre>
19
+ </body>
20
+ </html>
@@ -0,0 +1,20 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html>
7
+ <head>
8
+ <title>left_product! (CartesianIterator)</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
11
+ </head>
12
+ <body class="standalone-code">
13
+ <pre><span class="ruby-comment cmt"># File cartesian_iterator.rb, line 30</span>
14
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">left_product!</span>(<span class="ruby-identifier">other</span>)
15
+ <span class="ruby-ivar">@lists</span>.<span class="ruby-identifier">unshift</span> <span class="ruby-identifier">other</span>.<span class="ruby-identifier">to_a</span>.<span class="ruby-identifier">dup</span>
16
+ <span class="ruby-ivar">@tot_iter</span> <span class="ruby-operator">*=</span> <span class="ruby-ivar">@lists</span>[<span class="ruby-value">-1</span>].<span class="ruby-identifier">size</span>
17
+ <span class="ruby-keyword kw">self</span>
18
+ <span class="ruby-keyword kw">end</span></pre>
19
+ </body>
20
+ </html>
@@ -0,0 +1,19 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html>
7
+ <head>
8
+ <title>product (CartesianIterator)</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
11
+ </head>
12
+ <body class="standalone-code">
13
+ <pre><span class="ruby-comment cmt"># File cartesian_iterator.rb, line 36</span>
14
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">product</span>(<span class="ruby-identifier">other</span>)
15
+ (<span class="ruby-identifier">result</span> = <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">dup</span>).<span class="ruby-identifier">product!</span>(<span class="ruby-identifier">other</span>)
16
+ <span class="ruby-identifier">result</span>
17
+ <span class="ruby-keyword kw">end</span></pre>
18
+ </body>
19
+ </html>
@@ -0,0 +1,19 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html>
7
+ <head>
8
+ <title>left_product (CartesianIterator)</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
11
+ </head>
12
+ <body class="standalone-code">
13
+ <pre><span class="ruby-comment cmt"># File cartesian_iterator.rb, line 43</span>
14
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">left_product</span>(<span class="ruby-identifier">other</span>)
15
+ (<span class="ruby-identifier">result</span> = <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">dup</span>).<span class="ruby-identifier">left_product!</span>(<span class="ruby-identifier">other</span>)
16
+ <span class="ruby-identifier">result</span>
17
+ <span class="ruby-keyword kw">end</span></pre>
18
+ </body>
19
+ </html>
@@ -0,0 +1,39 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html>
7
+ <head>
8
+ <title>each (CartesianIterator)</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
11
+ </head>
12
+ <body class="standalone-code">
13
+ <pre><span class="ruby-comment cmt"># File cartesian_iterator.rb, line 48</span>
14
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">each</span>
15
+ <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">false</span> <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@tot_iter</span> <span class="ruby-operator">&lt;</span> <span class="ruby-value">1</span>
16
+
17
+ <span class="ruby-identifier">elems</span> = []
18
+ <span class="ruby-keyword kw">for</span> <span class="ruby-identifier">list</span> <span class="ruby-keyword kw">in</span> <span class="ruby-ivar">@lists</span>
19
+ <span class="ruby-identifier">elems</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">list</span>.<span class="ruby-identifier">restart_and_raw_next</span>
20
+ <span class="ruby-keyword kw">end</span>
21
+ <span class="ruby-keyword kw">if</span> <span class="ruby-constant">RUBY_VERSION</span> <span class="ruby-operator">&lt;=</span> <span class="ruby-value str">'1.9.1'</span>; <span class="ruby-keyword kw">yield</span> <span class="ruby-operator">*</span><span class="ruby-identifier">elems</span>.<span class="ruby-identifier">map</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">x</span><span class="ruby-operator">|</span> <span class="ruby-identifier">x</span> }; <span class="ruby-keyword kw">else</span>; <span class="ruby-keyword kw">yield</span> <span class="ruby-operator">*</span><span class="ruby-identifier">elems</span>; <span class="ruby-keyword kw">end</span>
22
+
23
+ <span class="ruby-identifier">last_list_index</span> = <span class="ruby-ivar">@lists</span>.<span class="ruby-identifier">size</span><span class="ruby-operator">-</span><span class="ruby-value">1</span>
24
+ <span class="ruby-identifier">n</span> = <span class="ruby-identifier">last_list_index</span>
25
+ <span class="ruby-identifier">loop</span> <span class="ruby-keyword kw">do</span>
26
+ <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">elems</span>[<span class="ruby-identifier">n</span>] = <span class="ruby-ivar">@lists</span>[<span class="ruby-identifier">n</span>].<span class="ruby-identifier">raw_next</span>
27
+ <span class="ruby-keyword kw">if</span> <span class="ruby-constant">RUBY_VERSION</span> <span class="ruby-operator">&lt;=</span> <span class="ruby-value str">'1.9.1'</span>; <span class="ruby-keyword kw">yield</span> <span class="ruby-operator">*</span><span class="ruby-identifier">elems</span>.<span class="ruby-identifier">map</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">x</span><span class="ruby-operator">|</span> <span class="ruby-identifier">x</span> }; <span class="ruby-keyword kw">else</span>; <span class="ruby-keyword kw">yield</span> <span class="ruby-operator">*</span><span class="ruby-identifier">elems</span>; <span class="ruby-keyword kw">end</span>
28
+ <span class="ruby-identifier">n</span> = <span class="ruby-identifier">last_list_index</span>
29
+ <span class="ruby-keyword kw">next</span>
30
+ <span class="ruby-keyword kw">elsif</span> <span class="ruby-identifier">n</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
31
+ <span class="ruby-identifier">elems</span>[<span class="ruby-identifier">n</span>] = <span class="ruby-ivar">@lists</span>[<span class="ruby-identifier">n</span>].<span class="ruby-identifier">restart_and_raw_next</span>
32
+ <span class="ruby-identifier">n</span> <span class="ruby-operator">-=</span> <span class="ruby-value">1</span>
33
+ <span class="ruby-keyword kw">else</span>
34
+ <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">true</span>
35
+ <span class="ruby-keyword kw">end</span>
36
+ <span class="ruby-keyword kw">end</span>
37
+ <span class="ruby-keyword kw">end</span></pre>
38
+ </body>
39
+ </html>
@@ -0,0 +1,112 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
+ <head>
8
+ <title>Module: Enumerable</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
+ <link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
12
+ <script type="text/javascript">
13
+ // <![CDATA[
14
+
15
+ function popupCode( url ) {
16
+ window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
17
+ }
18
+
19
+ function toggleCode( id ) {
20
+ if ( document.getElementById )
21
+ elem = document.getElementById( id );
22
+ else if ( document.all )
23
+ elem = eval( "document.all." + id );
24
+ else
25
+ return false;
26
+
27
+ elemStyle = elem.style;
28
+
29
+ if ( elemStyle.display != "block" ) {
30
+ elemStyle.display = "block"
31
+ } else {
32
+ elemStyle.display = "none"
33
+ }
34
+
35
+ return true;
36
+ }
37
+
38
+ // Make codeblocks hidden by default
39
+ document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
40
+
41
+ // ]]>
42
+ </script>
43
+
44
+ </head>
45
+ <body>
46
+
47
+
48
+
49
+ <div id="classHeader">
50
+ <table class="header-table">
51
+ <tr class="top-aligned-row">
52
+ <td><strong>Module</strong></td>
53
+ <td class="class-name-in-header">Enumerable</td>
54
+ </tr>
55
+ <tr class="top-aligned-row">
56
+ <td><strong>In:</strong></td>
57
+ <td>
58
+ <a href="../files/grid_search_rb.html">
59
+ grid_search.rb
60
+ </a>
61
+ <br />
62
+ </td>
63
+ </tr>
64
+
65
+ </table>
66
+ </div>
67
+ <!-- banner header -->
68
+
69
+ <div id="bodyContent">
70
+
71
+
72
+
73
+ <div id="contextContent">
74
+
75
+
76
+
77
+ </div>
78
+
79
+
80
+ </div>
81
+
82
+
83
+ <!-- if includes -->
84
+ <div id="includes">
85
+ <h3 class="section-bar">Included Modules</h3>
86
+
87
+ <div id="includes-list">
88
+ <span class="include-name"><a href="GridSearch.html">GridSearch</a></span>
89
+ </div>
90
+ </div>
91
+
92
+ <div id="section">
93
+
94
+
95
+
96
+
97
+
98
+
99
+
100
+
101
+ <!-- if method_list -->
102
+
103
+
104
+ </div>
105
+
106
+
107
+ <div id="validator-badges">
108
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
109
+ </div>
110
+
111
+ </body>
112
+ </html>
@@ -0,0 +1,160 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
+ <head>
8
+ <title>Module: GridSearch</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
+ <link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
12
+ <script type="text/javascript">
13
+ // <![CDATA[
14
+
15
+ function popupCode( url ) {
16
+ window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
17
+ }
18
+
19
+ function toggleCode( id ) {
20
+ if ( document.getElementById )
21
+ elem = document.getElementById( id );
22
+ else if ( document.all )
23
+ elem = eval( "document.all." + id );
24
+ else
25
+ return false;
26
+
27
+ elemStyle = elem.style;
28
+
29
+ if ( elemStyle.display != "block" ) {
30
+ elemStyle.display = "block"
31
+ } else {
32
+ elemStyle.display = "none"
33
+ }
34
+
35
+ return true;
36
+ }
37
+
38
+ // Make codeblocks hidden by default
39
+ document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
40
+
41
+ // ]]>
42
+ </script>
43
+
44
+ </head>
45
+ <body>
46
+
47
+
48
+
49
+ <div id="classHeader">
50
+ <table class="header-table">
51
+ <tr class="top-aligned-row">
52
+ <td><strong>Module</strong></td>
53
+ <td class="class-name-in-header">GridSearch</td>
54
+ </tr>
55
+ <tr class="top-aligned-row">
56
+ <td><strong>In:</strong></td>
57
+ <td>
58
+ <a href="../files/grid_search_rb.html">
59
+ grid_search.rb
60
+ </a>
61
+ <br />
62
+ </td>
63
+ </tr>
64
+
65
+ </table>
66
+ </div>
67
+ <!-- banner header -->
68
+
69
+ <div id="bodyContent">
70
+
71
+
72
+
73
+ <div id="contextContent">
74
+
75
+
76
+
77
+ </div>
78
+
79
+ <div id="method-list">
80
+ <h3 class="section-bar">Methods</h3>
81
+
82
+ <div class="name-list">
83
+ <a href="#M000014">argmax</a>&nbsp;&nbsp;
84
+ <a href="#M000015">argmin</a>&nbsp;&nbsp;
85
+ </div>
86
+ </div>
87
+
88
+ </div>
89
+
90
+
91
+ <!-- if includes -->
92
+
93
+ <div id="section">
94
+
95
+
96
+
97
+
98
+
99
+
100
+
101
+
102
+ <!-- if method_list -->
103
+ <div id="methods">
104
+ <h3 class="section-bar">Public Instance methods</h3>
105
+
106
+ <div id="method-M000014" class="method-detail">
107
+ <a name="M000014"></a>
108
+
109
+ <div class="method-heading">
110
+ <a href="GridSearch.src/M000014.html" target="Code" class="method-signature"
111
+ onclick="popupCode('GridSearch.src/M000014.html');return false;">
112
+ <span class="method-name">argmax</span><span class="method-args">(&amp;block)</span>
113
+ </a>
114
+ </div>
115
+
116
+ <div class="method-description">
117
+ <p>
118
+ Finds the argument which maximizes the function given in the block trhu
119
+ grid-search maximization.
120
+ </p>
121
+ <pre>
122
+ [-1,0,1,2].argmax {|x| x**2 } #=&gt; 2
123
+ </pre>
124
+ </div>
125
+ </div>
126
+
127
+ <div id="method-M000015" class="method-detail">
128
+ <a name="M000015"></a>
129
+
130
+ <div class="method-heading">
131
+ <a href="GridSearch.src/M000015.html" target="Code" class="method-signature"
132
+ onclick="popupCode('GridSearch.src/M000015.html');return false;">
133
+ <span class="method-name">argmin</span><span class="method-args">(&amp;block)</span>
134
+ </a>
135
+ </div>
136
+
137
+ <div class="method-description">
138
+ <p>
139
+ Finds the argument which minimizes the function given in the block trhu
140
+ grid-search minimization.
141
+ </p>
142
+ <pre>
143
+ [-1,0,1,2].argmin {|x| x**2 } #=&gt; 0
144
+ </pre>
145
+ </div>
146
+ </div>
147
+
148
+
149
+ </div>
150
+
151
+
152
+ </div>
153
+
154
+
155
+ <div id="validator-badges">
156
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
157
+ </div>
158
+
159
+ </body>
160
+ </html>