Export column of table as pandas or numpy.ndarray


I have a table ht which has a column named GQ, what is the best way to export
ht.GQ as a pandas or numpy object?

I found:


But I am not sure if this is the best way to do it.


You can get a python list of ints with:


Then convert to numpy/pandas as normal.

However, I really wouldn’t recommend this approach, and if you’re mixing Hail/numpy/pandas then you’re going to hit scaling issues really quickly.

My idea is to use Hail internally for my project, but in the end of the day I want to return to the end user a numpy.matrix with numbers, which is required for the rest of his/her pipeline.

ah, okay. In that case, this seems fine.