Getting Started Documentation Glish Learn More Programming Contact Us
Version 1.9 Build 1488
News FAQ
Search Home


next up previous contents index
Next: quanta - Tool Up: quanta - Module Previous: r_fill - Function


r_index - Function



Package general
Module quanta


Get index array for a record array


Synopsis
r_index(v, ...)


Arguments

v in a record array from which to extract elements
    Allowed: record (array)
... in slicing dimensions
    Allowed: integers, an index record, integer vectors


Returns
integer array


Description
r_index is a helper function for the record array functions. It returns an integer array with the selected elements.



Example
- print a := r_array(1:6,3,2)			# create a record array
[*29=1, *30=2, *31=3, *32=4, *33=5, *34=6]
- r_index(a)					# its index
[[1:3,]
    1 4
    2 5
    3 6] 
- r_index(a)::					# its shape 
[shape=[3 2] ] 
- r_index(a,2,)
[2 5]  
- r_index(a,2,)::
[shape=2] 
- r_index(a,2,2)
5 
- r_index(a,2,2)::
[=]





next up previous contents index
Next: quanta - Tool Up: quanta - Module Previous: r_fill - Function   Contents   Index
Please send questions or comments about AIPS++ to aips2-request@nrao.edu.
Copyright © 1995-2000 Associated Universities Inc., Washington, D.C.

Return to AIPS++ Home Page
2006-08-01