larray.AxisCollection.extend

AxisCollection.extend(axes, validate=True, replace_wildcards=False) None[source]

Extend the collection by appending the axes from axes.

Parameters
axessequence of Axis (list, tuple, AxisCollection)
validatebool, optional
replace_wildcardsbool, optional
Raises
TypeError

Raised if axes is not a sequence of Axis (list, tuple or AxisCollection)

Examples

>>> age = Axis(range(20), 'age')
>>> sex = Axis('sex=M,F')
>>> time = Axis([2007, 2008, 2009, 2010], 'time')
>>> col = AxisCollection(age)
>>> col.extend([sex, time])
>>> col
AxisCollection([
    Axis([0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19], 'age'),
    Axis(['M', 'F'], 'sex'),
    Axis([2007, 2008, 2009, 2010], 'time')
])