Skip to content

Data destruction during conversion to dataframe of nested arrays #3694

@JamesBrofos

Description

@JamesBrofos

Version of Awkward Array

2.8.9

Description and code to reproduce

Consider the following example:

>>> xxx = {
    "x": ["abc", "FG_12345"],
    "y": [None, ["g1", "g2"]]
}
>>> print(ak.to_dataframe(ak.Array(xxx)))  
                       x   y
entry subentry              
1     0         FG_12345  g1
      1         FG_12345  g2

As you can see, the "abc" data is completely lost during this conversion. This seems like a bug to me. I think that a more reasonable result would be

                       x    y
entry subentry               
0     0              abc  nan
1     0         FG_12345   g1
      1         FG_12345   g2

Metadata

Metadata

Assignees

Labels

bug (unverified)The problem described would be a bug, but needs to be triaged

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions