extensive scatter plot

2010-11-24 Thread Johannes Korn
Hi, I would like to produce a scatter plot with roughly 200 mio points. Because the points are so numerous I rather need a point density plot. I use numpy. Right now I loop over the individual data points and make a where query on a meshgrid. ind = where((x_grid == x_points[i]) & (y_grid == y_po

Reading bz2 file into numpy array

2010-11-22 Thread Johannes Korn
Hi, is there a convenient way to read bz2 files into a numpy array? I tried: from bz2 import * from numpy import * fd = BZ2File(filename, 'rb') read_data = fromfile(fd, float32) but BZ2File doesn't seem to produce a transparent filehandle. Kind regards! Johannes -- http://mail.python.org/mai