Entering edit mode
5.6 years ago
ja4123
▴
30
Someone can tell me how to load bed graph format to numpy as a vector? Part of a file looks like that:
4 13636 13687 1
4 13748 13799 1
4 26733 26754 1
4 26754 26776 2
4 26776 26785 3
4 26785 26791 4
I have added formatting to your post and changed the title to make it more explicit about what you are asking,
I would think a pandas DataFrame is more appropriate for this. Is there any reason you prefer a numpy vector?
It depends on what you want to do, but I second Pandas. Pandas is partly built on Numpy, so often when performing operations on dataframe series it is actually numpy under to hood running CPU optimized operations just like it would on a standard numpy array.