You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We've been making progress on getting Index and Series arithmetic&comparison methods to behave identically by having the Series versions wrap the Index implementations. To also make DataFrame behavior consistent, we're going to need to move those implementations from the Index subclasses to a shared mixin that will be mixed in to both the Index and Block subclasses (e.g. DatetimeIndex and DatetimeBlock both subclass DatetimeArray cc: @TomAugspurger).
To get from here to there, we need to standardize some some behavior and naming conventions that don't quite match between Index and Block. The analogous methods AFAICT are:
There is an inconsistency between Block.make_block and Block.make_block_same_class that needs to be resolved before these analogies become just a matter of naming convention. Block.make_block sets default values for the kwargs placement, ndim, while make_block_same_class only chooses a default for placement. ndim needs to be either added to make_block_same_class or removed from make_block in order for _get_attributes_dict to be definable.
The text was updated successfully, but these errors were encountered:
Related: #19431, #9859, #19294
We've been making progress on getting
Index
andSeries
arithmetic&comparison methods to behave identically by having theSeries
versions wrap theIndex
implementations. To also makeDataFrame
behavior consistent, we're going to need to move those implementations from theIndex
subclasses to a shared mixin that will be mixed in to both theIndex
andBlock
subclasses (e.g.DatetimeIndex
andDatetimeBlock
both subclassDatetimeArray
cc: @TomAugspurger).To get from here to there, we need to standardize some some behavior and naming conventions that don't quite match between Index and Block. The analogous methods AFAICT are:
Index.__new__
<-->internals.make_block
Index._shallow_copy_with_infer
<-->Block.make_block
Index._shallow_copy
<-->Block.make_block_same_class
Index._simple_new
<--> [needs implementation]There is an inconsistency between
Block.make_block
andBlock.make_block_same_class
that needs to be resolved before these analogies become just a matter of naming convention.Block.make_block
sets default values for the kwargsplacement, ndim
, whilemake_block_same_class
only chooses a default forplacement
.ndim
needs to be either added tomake_block_same_class
or removed frommake_block
in order for_get_attributes_dict
to be definable.The text was updated successfully, but these errors were encountered: