Returns an iterator of concatenated items from a sequence of arrays. Parameters ---------- seqarrays : sequence of arrays Sequence of arrays. fill_value : {None, integer} Value used to pad shorter iterables. flatten : {True, False}, Whether to
(seqarrays, fill_value=None, flatten=True)
| 299 | |
| 300 | |
| 301 | def _izip_records(seqarrays, fill_value=None, flatten=True): |
| 302 | """ |
| 303 | Returns an iterator of concatenated items from a sequence of arrays. |
| 304 | |
| 305 | Parameters |
| 306 | ---------- |
| 307 | seqarrays : sequence of arrays |
| 308 | Sequence of arrays. |
| 309 | fill_value : {None, integer} |
| 310 | Value used to pad shorter iterables. |
| 311 | flatten : {True, False}, |
| 312 | Whether to |
| 313 | """ |
| 314 | |
| 315 | # Should we flatten the items, or just use a nested approach |
| 316 | if flatten: |
| 317 | zipfunc = _izip_fields_flat |
| 318 | else: |
| 319 | zipfunc = _izip_fields |
| 320 | |
| 321 | for tup in itertools.zip_longest(*seqarrays, fillvalue=fill_value): |
| 322 | yield tuple(zipfunc(tup)) |
| 323 | |
| 324 | |
| 325 | def _fix_output(output, usemask=True, asrecarray=False): |