I have data which has a very particular format that I'm trying to store in a numpy array.
avi_05MSalt00001.txt 2012 Feb 07 20:12:41 50000 (usec) 300 10
I've defined the following numpy datatype:
timefile_dtype=numpy.dtype([
('filename', file),
('year', int),
('month', str), #Why don't these work?
('day', int),
('time', str),
('int_time', int),
('unit', str),
('avg', int),
('boxcar', int),
])
The output looks like this:'
('avidin_in_water00349.txt', 2012, '', 29, '', 50000, '', 300, 10)
Is it possible for numpy to store these string variables? If so, am I doing something wrong? I like the swiftness of this method rather than making my own list of lists...
Thanks.