Pandas broadcast with numpy scalars #8116
Labels
Compat
pandas objects compatability with Numpy or Python functions
Dtype Conversions
Unexpected or buggy dtype conversions
Reshaping
Concat, Merge/Join, Stack/Unstack, Explode
Milestone
Pandas objects (
Series
,DataFrame
, etc...) can broadcast operations with python scalars. For example:But when performing the same operation with a numpy scalar array:
pandas returns an error:
I can't find an explicit mention of scalar broadcasting in Pandas docs but this seems a natural case to be supported.
See also the original SO question.
The text was updated successfully, but these errors were encountered: