Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
interpolate w/ method=time does not work with timedeltas #6424
Comments
|
unless their is real interest, won't do this |
jreback
closed this
Feb 20, 2014
|
Can we leave this open then and mark as milestone "Someday"? |
jreback
added Enhancement Timedelta
labels
Feb 20, 2014
jreback
added this to the
Someday
milestone
Feb 20, 2014
jreback
reopened this
Feb 20, 2014
|
came up on SO http://stackoverflow.com/q/34315753/1240268 |
rldleblanc
commented
Jan 21, 2016
|
Run into this today as well. |
vtselfa
commented
May 2, 2016
|
I have also run into this today. |
|
If someone is interested in working on this, it'd follow a similar pattern to #14737 (convert to i8, interpolate, convert back to timedelta). |
|
@TomAugspurger i can take this up post #14737 :) |
|
@TomAugspurger is this still an issue? when i run the code fragment given in the initial post of this issue, i get this output
|
|
I filed this a long time ago, so bear with me. This does not seem to work: pd.DataFrame({'v':[1,np.nan,5]},index=pd.to_timedelta([1,2,3], unit="d")).interpolate(method="time")whereas this does: pd.DataFrame({'v':[1,np.nan,5]},index=pd.to_datetime([1,2,3], unit="d")).interpolate(method="time")I am seeing the same issue as in the above linked SO post. |
|
@cancan101 so it fails when we try to pass timedelta, is that correct? |
|
What do you mean? pd.DataFrame({'v':[1,np.nan,5]},index=pd.to_timedelta([1,2,3], unit="d")) |
|
@cancan101 yes that is fine, what i am trying to say is that it fails when you try to interpolate the timedelta data, pd.DataFrame({'v':[1,np.nan,5]},index=pd.to_timedelta([1,2,3], unit="d")).interpolate(method="time") whereas when you call interpolate for datetime data, it works. That is the difference between the two lines that you've posted earlier (as examples of what works and what doesnt), right? |
|
yes |
jreback
added Difficulty Intermediate Effort Low
labels
Dec 4, 2016
|
added this PR, #14799 |
cancan101 commentedFeb 20, 2014