| Library: | xplore |
| See also: | list append comp names |
| Macro: | addlist | |
| Description: | Adds components to an existing list or creates a new list with specific components. |
| Usage: | newlist=addlist({oldlist,} name1, value1 {,name2, value2, ...} | |
| Input: | ||
| oldlist | optional, string, name of an existing list to add components. | |
| name1, name2, ... | string, name of the list component. | |
| value1, value2, ... | numeric, string, or list, value of the list component. | |
| Output: | ||
| newlist | resulting list. | |
(2) The total number of input arguments is restricted to 20. -- This is not a real restriction, since the function can be applied subsequentially.
(3) As it holds for lists in general: there can be different list components with the same name.
library("xplore")
mylist=addlist("day",9831,"message","Hi!")
mylist=addlist(mylist,"question","Did you get it?")
mylist
Content of object mylist.day [1,] 9831 Content of object mylist.message [1,] "Hi!" Content of object mylist.question [1,] "Did you get it?"
| Library: | xplore |
| See also: | list append comp names |