Creates an NumPy array depending on the given data type and fill value.
If no fill_value is given a masked array will be returned.
Parameters: |
|
---|
Example
>>> createEmptyDataChunk(3, 'int', 10)
array([10, 10, 10])
>>> createEmptyDataChunk(6, np.dtype('complex128'), 0)
array([ 0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j])
>>> createEmptyDataChunk(3, 'f')
masked_array(data = [-- -- --],
mask = ...,
...)