Skip to content

Commit 495d0f4

Browse files
committed
DOC: update other concat docstring
1 parent 1e11919 commit 495d0f4

File tree

1 file changed

+13
-2
lines changed

1 file changed

+13
-2
lines changed

cycler.py

+13-2
Original file line numberDiff line numberDiff line change
@@ -390,14 +390,25 @@ def simplify(self):
390390
return reduce(add, (_cycler(k, v) for k, v in six.iteritems(trans)))
391391

392392
def concat(self, other):
393-
"""Concatenate two cyclers.
393+
"""Concatenate this cycler and an other.
394394
395395
The keys must match exactly.
396396
397+
This returns a single Cycler which is equivalent to
398+
`itertools.chain(self, other)`
399+
400+
Examples
401+
--------
402+
403+
>>> num = cycler('a', range(3))
404+
>>> let = cycler('a', 'abc')
405+
>>> num.concat(let)
406+
cycler('a', [0, 1, 2, 'a', 'b', 'c'])
407+
397408
Parameters
398409
----------
399410
other : `Cycler`
400-
The `Cycler` instances to concatenate to this one
411+
The `Cycler` to concatenate to this one.
401412
402413
Returns
403414
-------

0 commit comments

Comments
 (0)