Antoine Pitrou created ARROW-2148:
-------------------------------------

             Summary: [Python] to_pandas() on struct array returns object array
                 Key: ARROW-2148
                 URL: https://issues.apache.org/jira/browse/ARROW-2148
             Project: Apache Arrow
          Issue Type: Bug
            Reporter: Antoine Pitrou


This should probably return a Numpy struct array instead:

{code:python}
>>> arr = pa.array([{'a': 1, 'b': 2.5}, {'a': 2, 'b': 3.5}], 
>>> type=pa.struct([pa.field('a', pa.int32()), pa.field('b', pa.float64())]))
>>> arr.type
StructType(struct<a: int32, b: double>)
>>> arr.to_pandas()
array([{'a': 1, 'b': 2.5}, {'a': 2, 'b': 3.5}], dtype=object)
{code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to