API: arithmetic ops could accept an index as appropriate #4629
Labels
API Design
Dtype Conversions
Unexpected or buggy dtype conversions
Numeric Operations
Arithmetic, Comparison, and Logical operations
Milestone
Not sure if this will cause weirdness but haveing the arithmetic operations able to accept an index (when appropriate type), e.g. a datecolumn should be able to interact with a DatetimeIndex, but prob should prohibit an int column from interacting with a IntIndex?
e.g. in below
df['date']-df.index
should workThis actually DOES work now! (and I take it back, does make some sense)
should
df[1]-df.reset_index().index
work????http://stackoverflow.com/questions/18368442/how-to-directly-use-pandas-date-time-index-in-calculations/18368793?noredirect=1#comment26971689_18368793
The text was updated successfully, but these errors were encountered: