source: trunk/SRC/Documentation/idldoc_html_output/Matrix/extrac2.html @ 402

Last change on this file since 402 was 402, checked in by smasson, 15 years ago

update documentation

File size: 6.4 KB
Line 
1
2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
3 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
4
5<!-- Generated by IDLdoc 2.0 -->
6
7<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
8  <head>
9    <title>extrac2.pro (SAXO Documentation)</title>
10
11   
12    <link rel="stylesheet" type="text/css" media="all" href="./../main_files.css" />
13    <link rel="stylesheet" type="text/css" media="print" href="./../main_files_print.css" />
14   
15
16    <script type="text/javascript">
17      function setTitle() {
18        parent.document.title="extrac2.pro (SAXO Documentation)";
19      }
20    </script>
21  </head>
22
23  <body onload="setTitle();">
24
25    <div id="navbar_title">
26  <h1>SAXO Documentation</h1>
27</div>
28
29
30<div id="main_navbar">
31
32  <table cellspacing="0">
33    <tr>
34     
35      <td><a href="./../overview.html" title="Overview of library">Overview</a></td>
36     
37
38     
39      <td >Directory</td>
40     
41
42     
43      <td><a href="./../idldoc-categories.html" title="Browse library by category">Categories</a></td>
44     
45
46     
47      <td><a href="./../idldoc-index.html" title="Index of files, routines, and parameters">Index</a></td>
48     
49
50     
51      <td><a href="./../search-page.html" title="Search library">Search</a></td>
52     
53
54      <td id="selected">File</td>
55
56     
57      <td><a href="../../../Matrix//extrac2.pro" title="Source code of a file">Source</a></td>
58     
59
60     
61      <td><a href="./../idldoc-help.html" title="Help on IDLdoc">Help</a></td>
62     
63
64      <td >Etc</td>
65
66      <td id="flexible">Developer&nbsp;documentation</td>
67    </tr>
68  </table>
69
70</div>
71
72<div id="secondary_navbar">
73
74<a href="different.html">&lt;&lt;prev file</a> | <a href="inter.html">next file &gt;&gt;</a>&nbsp;&nbsp;&nbsp;&nbsp;<a href="extrac2.html" target="_TOP">view single page</a> | <a href="./../index.html" target="_TOP">view frames</a>&nbsp;&nbsp;&nbsp;&nbsp;summary: fields | routine&nbsp;&nbsp;&nbsp;&nbsp;details: <a href="#routine_details">routine</a>
75
76</div>
77
78
79    <div id="container">
80
81      <h1 class="directory"><a href="directory-overview.html">Matrix/</a></h1>
82      <h2 class="pro_file">extrac2.pro</h2>
83
84      <div id="file_attr">
85        <dl>
86        </dl>
87      </div>
88
89      <div id="file_comments">
90 extraction of subdomains of matrices;
91 Even if the subdomain is "pierced" (see the example)
92 By default, IDL can make extractions of subdomain:
93
94   IDL> a=indgen(5,5)
95   IDL> print, a
96             0       1       2       3       4
97             5       6       7       8       9
98            10      11      12      13      14
99            15      16      17      18      19
100            20      21      22      23      24
101   IDL> print, a[[0,2],3]
102            15      17
103   IDL> print, a[[0,2],*]
104             0       2
105             5       7
106            10      12
107            15      17
108            20      22
109 but
110   IDL> print, a[[0,2],[3,4]]
111            15      22
112 while
113   IDL> print, extrac2(a,[0,2],[3,4])
114            15      17
115            20      22
116</div>
117
118     
119
120     
121
122     
123
124     
125
126      <div id="routine_details">
127       
128
129        <div class="routine_details" id="_extrac2">
130
131          <h2><a class="top" href="#container">top</a>extrac2 <span class="categories">
132 Utilities
133</span></h2>
134       
135          <p class="header">
136            <span class="result">result = </span>extrac2(<span class="result"><a href="#_extrac2_param_array">array</a>, <a href="#_extrac2_param_index1">index1</a>, <a href="#_extrac2_param_index2">index2</a>, <a href="#_extrac2_param_index3">index3</a>, <a href="#_extrac2_param_index4">index4</a></span>)</p>
137       
138          <div class="comments">
139</div>
140
141          <h3>Return value</h3><div class="preformat">
142 a matrix 1d, 2d, 3d or 4d extract from input array
143 -1 in case of mistake
144</div>
145
146         
147            <h3>Parameters</h3>
148       
149           
150            <h4 id="_extrac2_param_array">array&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
151              <span class="attr">in</span>
152             
153             
154              <span class="attr">required</span>
155             
156             
157             
158             
159            </h4>
160       
161          <div class="comments">
162 a 1d, 2d, 3d or 4d input array
163</div>
164           
165            <h4 id="_extrac2_param_index1">index1&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
166              <span class="attr">in</span>
167             
168             
169              <span class="attr">required</span>
170             
171             
172             
173             
174            </h4>
175       
176          <div class="comments">
177 can have 2 forms:
178
179  1) a vector containing indexes of lines we want to keep
180  2) the string '*' if we want to keep all lines.
181</div>
182           
183            <h4 id="_extrac2_param_index2">index2&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
184              <span class="attr">in</span>
185             
186             
187              <span class="attr">required</span>
188             
189             
190             
191             
192            </h4>
193       
194          <div class="comments">
195 the same thing that index1 but for dim 2.
196</div>
197           
198            <h4 id="_extrac2_param_index3">index3&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
199              <span class="attr">in</span>
200             
201             
202              <span class="attr">required</span>
203             
204             
205             
206             
207            </h4>
208       
209          <div class="comments">
210 the same thing that index1 but for dim 3.
211</div>
212           
213            <h4 id="_extrac2_param_index4">index4&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
214              <span class="attr">in</span>
215             
216             
217              <span class="attr">required</span>
218             
219             
220             
221             
222            </h4>
223       
224          <div class="comments">
225 the same thing that index1 but for dim 4.
226</div>
227           
228
229         
230
231         
232
233          <h3>Examples</h3><div class="preformat">
234 I have a 2d matrix named A. I want extract a small intersection
235 matrix 2d of the line 2, 3 and 7 and of the column 0 and 1:
236
237   IDL> res=extrac2(A,[2,3,7],[0,1])
238
239 other ex:
240   IDL> a=[['a','b','c'],['d','e','f'],['g','h','i']]
241   IDL> print, a
242 a b c
243 d e f
244 g h i
245   IDL> print, extrac2(a,[0,2],[0,2])
246 a c
247 g i
248</div>
249          <h3>Version history</h3>
250         
251          <h4>Version</h4><div class="preformat">
252 $Id: extrac2.pro 373 2008-08-08 14:11:31Z pinsard $
253</div>
254          <h4>History</h4><div class="preformat">
255 Sebastien Masson (smasson@lodyc.jussieu.fr)
256  - 12/1/1999
257  - 29/4/1999: correction of a bug and complement of the heading
258</div>
259         
260         
261          <h3>Known issues</h3>
262         
263         
264         
265          <h4>Restrictions</h4><div class="preformat">
266</div>
267       
268         
269         
270         
271         
272         
273         
274         
275       
276          <h3>Statistics</h3>
277          <table class="statistics">
278            <tr><td>McCabe cyclic</td><td>          14</td></tr>
279            <tr><td>McCabe essential</td><td>           1</td></tr>
280            <tr><td>McCabe modular design</td><td>           1</td></tr>
281          </table>
282         
283       
284        </div>
285       
286      </div>
287
288     
289
290      <div id="tagline">Produced by IDLdoc 2.0.</div>
291
292    </div>
293
294  </body>
295</html>
Note: See TracBrowser for help on using the repository browser.