File: tars.m

package info (click to toggle)
octave-struct 1.0.5-1
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 260 kB
  • ctags: 8
  • sloc: makefile: 64; sh: 4
file content (15 lines) | stat: -rw-r--r-- 395 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
## s = tars (foo,bar, ... ) == struct ("foo",foo,"bar",bar,...)
##
## Groups foo, bar, ... into a struct whose fields are "foo", "bar" ...
## and such that s.foo == foo, s.bar == bar ...  
##
## See also : untar

## Author:        Etienne Grossmann <etienne@isr.ist.utl.pt>
## Last modified: October 2000

function s = tars(varargin)

for i=1:nargin
   s.(deblank(argn(i,:))) = varargin{i};
end