+
    xȇiy                         ^ RI t^ RIt^ RIHu Ht ^ RIt^ RIH	t	H
t
HtHtHt ^ RIHt ]P"                  ! . ROR7      R 4       t]P"                  ! . R	OR7      R 4       t ! R R4      tR# )
    N)Index
MultiIndexSeries
date_rangeisna)paramsc                :    V P                   pVR9   d   R^/M/ pW3# )zFixture that returns an (method name, required kwargs) pair.

This fixture does not include method 'time' as a parameterization; that
method requires a Series with a DatetimeIndex, and is generally tested
separately from these non-temporal methods.
orderspline
polynomialparamrequestmethodkwargss   &  |/Users/max/.openclaw/workspace/postharvest/venv/lib/python3.14/site-packages/pandas/tests/series/methods/test_interpolate.pynontemporal_methodr      s(    8 ]]F#'??gq\RF>    c                :    V P                   pVR9   d   R^/M/ pW3# )zFixture that returns a (method name, required kwargs) pair to
be tested for various Index types.

This fixture does not include methods - 'time', 'index', 'nearest',
'values' as a parameterization
r
   r   r   r   s   &  r   interp_methods_indr   2   s(    2 ]]F#'??gq\RF>r   c                   "  a  ] tR t^Pt o ]P
                  P                  RR7      R 4       tR tR t	R t
R tR tR	 tR
 t]P
                  P                  R/ ]P                   ! RRR^/]P$                  ! R4      R7      .4      R 4       tR tR t]P
                  P                  R/ ]P                   ! RRR^/]P$                  ! R4      R7      .4      R 4       tR tR tR tR tR t]P
                  P                  RRP^ .4      R 4       tR t]P
                  P                  RRR.4      R  4       tR! tR" t R# t!R$ t"]P
                  P                  R%]#PH                  ]#PH                  ^]#PH                  ]#PH                  ]#PH                  ^]#PH                  ]#PH                  .	RR&R'R(/3]#PH                  ]#PH                  ^]#PH                  ]#PH                  ]#PH                  ^]#PH                  ]#PH                  .	RR&R'R(R^/3]#PH                  ]#PH                  ^]#PH                  ]#PH                  ]#PH                  ^]#PH                  ]#PH                  .	RR&R'R)/3]#PH                  ]#PH                  ^]#PH                  ]#PH                  ]#PH                  ^]#PH                  ]#PH                  .	RR&R'R)R^/3]#PH                  ]#PH                  ]#PH                  ]#PH                  ]#PH                  ]#PH                  ]#PH                  .RR&R'R)R^/3]%! ^4      RR&R'R)R^/334      R* 4       t&]P
                  P                  R%]#PH                  ]#PH                  ^]#PH                  ]#PH                  ]#PH                  ^]#PH                  ]#PH                  .	RR+R'R(/3]#PH                  ]#PH                  ^]#PH                  ]#PH                  ]#PH                  ^]#PH                  ]#PH                  .	RR+R'R(R^/3]#PH                  ]#PH                  ^]#PH                  ]#PH                  ]#PH                  ^]#PH                  ]#PH                  .	RR+R'R)/3]#PH                  ]#PH                  ^]#PH                  ]#PH                  ]#PH                  ^]#PH                  ]#PH                  .	RR+R'R)R^/334      R, 4       t'R- t(R. t)R/ t*R0 t+]P
                  P                  R1R2]P                   ! R3]P$                  ! R4      R7      .4      R4 4       t,R5 t-]P
                  P                  RR6R&.4      R7 4       t.R8 t/R9 t0]P
                  P                  RRR:.4      R; 4       t1]P
                  P                  RRPRQ^ R<]#PH                  .4      R= 4       t2R> t3R? t4R@ t5RA t6RB t7RC t8RD t9]P
                  P                  RE. RRO]:Pv                  ! RF^RG7      ]:Px                  ! ^ ^RH7      .4      RI 4       t=RJ t>]P
                  P                  RKR3. RSO3R2. RTO3.4      RL 4       t?RM t@RN tAROtBV tCR# )UTestSeriesInterpolateDataz)EA.fillna does not handle 'linear' methodreasonc                0   \        \        R ^R7      4      pVP                  4       p\        P                  V^&   VP
                  P                  R4      pVP                  4       pVP
                  P                  R4      p\        P                  ! WE4       R# )z
2012-01-01)periodsDN)
r   r   copypdNaTdt	to_periodinterpolatetmassert_series_equal)selforigserser_perres_perexpected_pers   &     r   test_interpolate_period_values8TestSeriesInterpolateData.test_interpolate_period_valuesQ   sq    jq9:iikA &&""3'%%'ww((-
w5r   c                v   \        \        P                  ! \        V4      \        R 7      VP
                  4      pVP                  4       p\        P                  VR&   \        P                  VR&   VP                  RR7      p\        P                  ! WB4       \        VP
                   Uu. uF  qUP                  4       NK  	  upVP
                  R7      P                  \        4      pVP                  4       p\        P                  VR&   VP                  RR7      p\        P                  ! W4       R# u upi )	dtype:      N:   	   Nlinearr   index:   
   NtimeN)r   nparangelenfloatr:   r    nanr%   r&   r'   	toordinalastype)	r(   datetime_serieststs_copylinear_interpdord_tsord_ts_copytime_interps	   &&       r   test_interpolate*TestSeriesInterpolateData.test_interpolate]   s    BIIc/2%@/BWBWX'')
 vvvv++8+<
}1$3$9$9:$9q[[]$9:/BWBW

&- 	 kkmFFD!--V-<
{3 ;s   +D6c                    \        ^ ^^\        P                  .4      pRp\        P                  ! \
        VR7      ;_uu_ 4        VP                  RR7       RRR4       R#   + '       g   i     R# ; i)r   zGtime-weighted interpolation only works on Series.* with a DatetimeIndexmatchr=   r8   Nr   r>   rB   pytestraises
ValueErrorr%   )r(   non_tsmsgs   &  r   /test_interpolate_time_raises_for_non_timeseriesITestSeriesInterpolateData.test_interpolate_time_raises_for_non_timeseriesu   sQ     Aq"&&)*W]]:S11f- 2111s   A!!A2	c                   \         P                  ! R 4       \        . RO4      p\        . RO\        . RO4      R7      pVP                  P                  \        . R	O4      4      P                  \        4      pVP                  V4      P                  RR7      P                  R,          p\        P                  ! WB4       R# )
scipyr9   cubicspliner8   r3      NNr<            	      &@g     &@g      '@g     '@      (@g     (@g      )@g     )@      *@	      ?      ?      ?      ?       @      @      @      @      @ri   rj   rk   rm   rn   ro   )rS   importorskipr   r   r:   unionrD   rA   reindexr%   locr&   r'   )r(   r*   expected	new_indexresults   &    r   test_interpolate_cubicspline6TestSeriesInterpolateData.test_interpolate_cubicspline}   s    G$%&KIJ

 IIOOE*L$MNUU
	 Y'33=3IMMcR
v0r   c                   \         P                  ! R 4       \        \        P                  ! \        P
                  P                  ^4      P                  ^dR7      4      4      pVP                  P                  \        . RO4      4      P                  \        4      pVP                  V4      P                  RR7      pVP                  R,           R# )r[   )sizepchipr8   :1   3   NN)g     H@g     H@g     H@g      I@g     @I@g     `I@)rS   rr   r   r>   sortrandomdefault_rnguniformr:   rs   r   rD   rA   rt   r%   ru   )r(   r*   rw   interp_ss   &   r   test_interpolate_pchip0TestSeriesInterpolateData.test_interpolate_pchip   s    G$RWWRYY2215==3=GHI IIOO:;

&- 	 ;;y)55W5EUr   c                   \         P                  ! R 4       \        . RO4      p\        . RO\        . R	O4      R7      pVP                  P                  \        . R
O4      4      P                  \        4      pVP                  V4      P                  RR7      p\        P                  ! VP                  R,          V4       \        . RO\        . R	O4      R7      pVP                  P                  \        . R
O4      4      P                  \        4      pVP                  V4      P                  R^R7      p\        P                  ! VP                  R,          V4       R# )r[   r9   akimar8   r]   )r   derNr_   rc   rg   rq   )	rd   rh   rh   rh   re   rh   rh   rh   rf   rS   rr   r   r   r:   rs   rD   rA   rt   r%   r&   r'   ru   r(   r*   rv   rw   r   s   &    r   test_interpolate_akima0TestSeriesInterpolateData.test_interpolate_akima   s   G$%& KIJ
 IIOOE*L$MNUU
	 ;;y)55W5E
x||C0(; <IJ
 IIOOE*L$MNUU
	 ;;y)55W!5L
x||C0(;r   c                   \         P                  ! R 4       \        . RO4      p\        . RO\        . RO4      R7      pVP                  P                  \        . R	O4      4      P                  \        4      pVP                  V4      P                  RR7      p\        P                  ! VP                  R,          V4       R# )
r[   r9   piecewise_polynomialr8   r]   Nr_   rc   rg   rq   r   r   s   &    r   %test_interpolate_piecewise_polynomial?TestSeriesInterpolateData.test_interpolate_piecewise_polynomial   s    G$%&KIJ

 IIOOE*L$MNUU
	 ;;y)55=S5T
x||C0(;r   c                   \         P                  ! R 4       \        . RO4      p\        . RO\        . RO4      R7      pVP                  P                  \        . R	O4      4      P                  \        4      pVP                  V4      P                  RR7      p\        P                  ! VP                  R,          V4       R# )
r[   r9   from_derivativesr8   r]   Nr_   rc   rg   rq   r   r   s   &    r   !test_interpolate_from_derivatives;TestSeriesInterpolateData.test_interpolate_from_derivatives   s    G$%&KIJ

 IIOOE*L$MNUU
	 ;;y)55=O5P
x||C0(;r   r   r   r   r
   r[   )marksc                2   \        \        P                  \        P                  .4      p\        P                  ! VP
                  ! R/ VB V4       \        . \        R 7      P                  4       p\        P                  ! VP
                  ! R/ VB V4       R# )r1   N )r   r>   rB   r&   r'   r%   object)r(   r   ss   && r   test_interpolate_corners2TestSeriesInterpolateData.test_interpolate_corners   sh     BFFBFF#$
q}}6v6:2V$002
q}}6v6:r   c                *   \        \        P                  \        P                  ! \        P                  P                  ^4      P	                  ^4      4      R7      p\        P                  P                  ^4      P                  ^
4      VP                  R&   VP                  P                  P                  \        4      pVP                  RR7      p\        V4      pV( p\        \        P                  ! W$,          W%,          VP                  V,          4      VP                  V,          R7      p\        P                   ! W4,          V4       VP                  RR7      p\        P                   ! Ws4       \        P                   ! Wt,          V4       R# )   r9   :NNr^   r:   r8   valuesN)r   r>   rB   r   r   r   standard_normalru   r:   r   rD   rA   r%   r   interpr&   r'   )r(   r   valsrx   badgoodrv   other_results   &       r   test_interpolate_index_values7TestSeriesInterpolateData.test_interpolate_index_values   s   266)>)>q)A)H)H)L!MNYY**1-==bAc
ww~~$$U+g.1gtIIdiQXXd^<AGGCL
 	v{H5 }}H}5
|4
|0(;r   c                &   \        ^^\        P                  \        P                  \        P                  ^.4      pRp\        P                  ! \
        VR7      ;_uu_ 4        VP                  RR7       RRR4       R#   + '       g   i     R# ; i)r3   zStime-weighted interpolation only works on Series or DataFrames with a DatetimeIndexrP   r=   r8   NrR   r(   r   rW   s   &  r   test_interpolate_non_ts1TestSeriesInterpolateData.test_interpolate_non_ts   s_    Aq"&&"&&"&&"56# 	 ]]:S11MMM( 2111s   "A??B	c                    \        ^ ^\        P                  ^.4      pVP                  ! R/ VB p\        . RO4      p\        P
                  ! W44       R# )r   Nr           rh   rl   rp   r   r>   rB   r%   r&   r'   )r(   r   r   rx   rv   s   &&   r   test_nan_interpolate.TestSeriesInterpolateData.test_nan_interpolate   sE     Aq"&&!$%((./
v0r   c                    \        ^^\        P                  ^.. ROR7      pVP                  4       p\        . RO. ROR7      p\        P
                  ! W#4       R# )r3   r9   N)r3   r^   r;   r6   )rh   rl   rp         @r   r(   r   rx   rv   s   &   r   test_nan_irregular_index2TestSeriesInterpolateData.test_nan_irregular_index  sA    Aq"&&!$L9.lC
v0r   c                    \        ^ ^^\        P                  .\        R4      R7      pVP	                  4       p\        . RO\        R4      R7      p\
        P                  ! W#4       R# )r   abcdr9   N)r   rh   rl   rl   )r   r>   rB   listr%   r&   r'   r   s   &   r   test_nan_str_index,TestSeriesInterpolateData.test_nan_str_index  sI    Aq!RVV$DL9.d6lC
v0r   c                    \         P                  ! R 4       \        ^^\        P                  ^.. ROR7      pVP                  RR7      p\        . RO. ROR7      p\        P                  ! W#4       R# )r[   r9   	quadraticr8   N)r3   r   r^   r4   )rh   r         "@g      0@rS   rr   r   r>   rB   r%   r&   r'   )r(   sqrx   rv   s   &   r   test_interp_quad*TestSeriesInterpolateData.test_interp_quad  sT    G$Q2662&l;{3/|D
v0r   c                   \         P                  ! R 4       \        ^^\        P                  ^\        P                  ^.4      p\        . R	O4      pVP                  RR7      p\        P                  ! W24       VP                  RR7      p\        P                  ! W24       \        . R
O4      pVP                  RR7      p\        P                  ! W2P                  R4      4       VP                  RR7      p\        P                  ! W24       \        . R
O4      pVP                  RR7      p\        P                  ! W2P                  R4      4       VP                  RR7      p\        P                  ! W24       \        . RO4      pVP                  RR7      p\        P                  ! W24       VP                  RR7      p\        P                  ! W24       \        . RO4      pVP                  RR7      p\        P                  ! W24       R# )r[   slinearr8   nearestrA   zeror   cubicN)rh   rp   g      @re   g     2@      9@)r3   r^   r^   ra   ra   r   )r3   rp   g:/KK@re   gL82@r   )rh   rp   g333333@re   g3333332@r   )	rS   rr   r   r>   rB   r%   r&   r'   rD   r(   r   rv   rx   s   &   r   test_interp_scipy_basic1TestSeriesInterpolateData.test_interp_scipy_basic!  s   G$Aq"&&"bffb12;<i0
v0i0
v012i0
vw'?@i0
v012f-
vw'?@f-
v0 CDk2
v0k2
v0;<g.
v0r   c                   \        ^^\        P                  \        P                  \        P                  ^.4      p\        RRRR\        P                  R.4      pVP                  R^R7      p\        P
                  ! W24       R# )	r3   rh   rp         @      @rd   r7   r   limitNr   r   s   &   r   test_interp_limit+TestSeriesInterpolateData.test_interp_limitE  s`    Aq"&&"&&"&&"563S#rvvt<=ha8
v0r   r   c           	         \        ^^\        P                  ^.4      pVw  rE\        P                  ! \
        RR7      ;_uu_ 4        VP                  ! RRVRV/VB  RRR4       R#   + '       g   i     R# ; i)r3   zLimit must be greater than 0rP   r   r   Nr   rR   )r(   r   r   r   r   r   s   &&&   r   *test_interpolate_invalid_nonpositive_limitDTestSeriesInterpolateData.test_interpolate_invalid_nonpositive_limitL  s]     Aq"&&!$%+]]:-KLLMM??f?? MLLLs   A''A8	c           	         \        ^^\        P                  ^.4      pVw  r4Rp\        P                  ! \
        RR7      ;_uu_ 4        VP                  ! RRVRV/VB  RRR4       R#   + '       g   i     R# ; i)r3   rl   zLimit must be an integerrP   r   r   Nr   rR   )r(   r   r   r   r   r   s   &&    r   $test_interpolate_invalid_float_limit>TestSeriesInterpolateData.test_interpolate_invalid_float_limitT  s`    Aq"&&!$%+]]:-GHHMM??f?? IHHHs   A))A:	invalid_methodNnonexistent_methodc                   \        ^^\        P                  ^\        P                  ^.4      pRpVf   Rp\        P                  ! \
        VR7      ;_uu_ 4        VP                  VR7       RRR4       \        P                  ! \
        VR7      ;_uu_ 4        VP                  VRR7       RRR4       R#   + '       g   i     LR; i  + '       g   i     R# ; i)r3   z2Can not interpolate with method=nonexistent_methodNz%'method' should be a string, not NonerP   r8   r   rR   )r(   r   r   rW   s   &&  r   test_interp_invalid_method4TestSeriesInterpolateData.test_interp_invalid_method\  s    Aq"&&"bffb12B!9C]]:S11MMM0 2
 ]]:S11MMrM: 21 21
 211s   B7C
7C	
C	c                b   \        ^^\        P                  \        P                  \        P                  ^.4      p\        RRRR\        P                  R.4      pVP                  R^RR7      p\        P
                  ! W24       VP                  R^R	R7      p\        P
                  ! W24       R
# )r3   rh   rp   r   r   rd   r7   forwardr   r   limit_directionFORWARDNr   r   s   &   r   test_interp_limit_forward3TestSeriesInterpolateData.test_interp_limit_forwardk  s    Aq"&&"&&"&&"56 3S#rvvt<=haS
v0haS
v0r   c           
     L   \        \        P                  R R\        P                  \        P                  \        P                  R\        P                  .4      p\        . RO4      pVP                  RRR7      p\        P
                  ! W24       \        \        P                  R RRRRRR.4      pVP                  RR	R7      p\        P
                  ! W24       \        R R RRRRR\        P                  .4      pVP                  RR
R7      p\        P
                  ! W24       R# )rh   rp   rd   r   r   r   r7   bothr   r   r   backwardN)rh   rh   rp   r   r   r   rd   rd   r   r   s   &   r   test_interp_unlimited/TestSeriesInterpolateData.test_interp_unlimitedw  s    BFFCbffbffbffdBFFKLDEhG
v02663S#sD$GHh	J
v03S#sCrvvFGh
K
v0r   c                   \        ^^\        P                  \        P                  \        P                  ^.4      pRp\        P                  ! \
        VR7      ;_uu_ 4        VP                  R^RR7       RRR4       \        P                  ! \
        VR7      ;_uu_ 4        VP                  RRR7       RRR4       R#   + '       g   i     LR; i  + '       g   i     R# ; i)r3   zVInvalid limit_direction: expecting one of \['forward', 'backward', 'both'\], got 'abc'rP   r7   abcr   Nr   rR   r   s   &  r   test_interp_limit_bad_direction9TestSeriesInterpolateData.test_interp_limit_bad_direction  s    Aq"&&"&&"&&"56/ 	 ]]:S11MMEMJ 2 ]]:S11MM5MA 21	 21 211s   "C#CC	C%	c                   \        \        P                  \        P                  ^\        P                  \        P                  \        P                  ^\        P                  \        P                  .	4      p\        \        P                  \        P                  RRRRR\        P                  \        P                  .	4      pVP                  RRR7      p\        P
                  ! W24       \        \        P                  \        P                  RR\        P                  \        P                  R\        P                  \        P                  .	4      pVP                  RR^R	7      p\        P
                  ! W24       \        \        P                  \        P                  RR\        P                  RR\        P                  \        P                  .	4      pVP                  RRR
^R7      p\        P
                  ! W24       \        \        P                  \        P                  R\        P                  \        P                  \        P                  RRR.	4      pVP                  RRR7      p\        P
                  ! W24       \        \        P                  \        P                  R\        P                  \        P                  \        P                  RR\        P                  .	4      pVP                  RR^R	7      p\        P
                  ! W24       \        \        P                  RR\        P                  \        P                  \        P                  RR\        P                  .	4      pVP                  RRR
^R7      p\        P
                  ! W24       \        RRR\        P                  \        P                  \        P                  R\        P                  \        P                  .	4      pVP                  RRRR7      p\        P
                  ! W24       Rp\        P                  ! \        VR7      ;_uu_ 4        VP                  RRR7       RRR4       R#   + '       g   i     R# ; i)r^   rp   r   r         @r   r7   inside)r   
limit_area)r   r   r   r   )r   r   r   r   outsider   )r   r   r   zEInvalid limit_area: expecting one of \['inside', 'outside'\], got abcrP   r   N)	r   r>   rB   r%   r&   r'   rS   rT   rU   )r(   r   rv   rx   rW   s   &    r   test_interp_limit_area0TestSeriesInterpolateData.test_interp_limit_area  s   BFFBFFArvvrvvrvvq"&&"&&QR2662663S#sBFFBFFSTh8D
v0VVRVVS#rvvrvvsBFFBFFK
 h81M
v02662663RVVS#rvvrvvVW&PQ  
 	v02662663SRUVWh9E
v0VVRVVS"&&"&&"&&#sBFFK
 h9AN
v02663RVVRVVRVVS#rvvVW	6QR  
 	v03S"&&"&&"&&#rvvrvvVW	:  
 	v0 W]]:S11MMeM< 2111s   Q%%Q6	zdata, kwargspadr   r   r   c                    \        V4      pR p\        P                  ! \        VR7      ;_uu_ 4        VP                  ! R/ VB  RRR4       R#   + '       g   i     R# ; i)#Can not interpolate with method=padrP   Nr   r   rS   rT   rU   r%   r(   datar   r   rW   s   &&&  r   test_interp_limit_area_with_pad9TestSeriesInterpolateData.test_interp_limit_area_with_pad  sB    @ 4L3]]:S11MM#F# 2111   AA 	bfillc                    \        V4      pR p\        P                  ! \        VR7      ;_uu_ 4        VP                  ! R/ VB  RRR4       R#   + '       g   i     R# ; i)z%Can not interpolate with method=bfillrP   Nr   r   r   s   &&&  r   $test_interp_limit_area_with_backfill>TestSeriesInterpolateData.test_interp_limit_area_with_backfill  sA    . 4L5]]:S11MM#F# 2111r   c                ~   \        ^^\        P                  \        P                  \        P                  ^.4      p\        RR\        P                  RRR.4      pVP                  R^RR7      p\        P
                  ! W24       \        RRR	\        P                  RR.4      pVP                  R^R
R7      p\        P
                  ! W24       \        ^^\        P                  \        P                  \        P                  ^^	\        P                  \        P                  ^\        P                  .4      p\        . RO4      pVP                  R^R
R7      p\        P
                  ! W24       \        RRR\        P                  RRRRRRR.4      pVP                  R^R
R7      p\        P
                  ! W24       R# )r3   rh   rp   r   r   rd   r7   r   r   r   r   r   r         $@re   N)rh   rp   r   r   r   r   r   r  rd   re   re   r   r   s   &   r   test_interp_limit_direction5TestSeriesInterpolateData.test_interp_limit_direction  sS   Aq"&&"&&"&&"563RVVS#t<=haT
v03S"&&#t<=haP
v0 Aq"&&"&&"&&!QBFFSTUVhaP
v0#sBFFCc4tTJ
 haP
v0r   c                |   \        \        P                  \        P                  ^^^	\        P                  .4      p\        RRRRR\        P                  .4      pVP                  R^RR7      p\        P
                  ! W24       \        . R	O4      pVP                  R^RR7      p\        P
                  ! W24       R# )
r;   r   r   r   r7   r   r   r   N)r   r   r   r   r   r   r   r   s   &   r   test_interp_limit_to_ends3TestSeriesInterpolateData.test_interp_limit_to_ends  s    BFFBFFAq!RVV453S#sBFF;<haT
v089haP
v0r   c                   \        \        P                  \        P                  ^^\        P                  \        P                  .4      p\        \        P                  \        P                  RRR\        P                  .4      pVP                  R^RR7      p\        P
                  ! W24       \        \        P                  RRR\        P                  \        P                  .4      pVP                  R^RR7      p\        P
                  ! W24       \        \        P                  RRRR\        P                  .4      pVP                  R^RR7      p\        P
                  ! W24       R# )	r;   r   r   r7   r   r   r   r   Nr   r   s   &   r   test_interp_limit_before_ends7TestSeriesInterpolateData.test_interp_limit_before_ends+  s    BFFBFFAq"&&"&&9:2662663S"&&ABhaS
v02663S"&&"&&ABhaT
v02663S#rvv>?haP
v0r   c                    \         P                  ! R 4       \        . RO4      pVP                  R^R7      p\        P
                  ! W!4       VP                  4       p\        P
                  ! W!4       R# )r[   r   r   r
   Nr3   r   r^   )rS   rr   r   r%   r&   r'   )r(   r   rx   s   &  r   test_interp_all_good.TestSeriesInterpolateData.test_interp_all_good;  sU    G$9l!<
v) 
v)r   check_scipyFTc                   \         P                  ! . RO4      p\        ^^\        P                  .VR7      pVP                  4       p^VP                  ^&   VP                  4       p\        P                  ! WT4       RpV'       dC   \        P                  ! \        VR7      ;_uu_ 4        VP                  R^R7       RRR4       R# R#   + '       g   i     R# ; i)r   r9   z?Only `method=linear` interpolation is supported on MultiIndexesrP   r   r  N))r   a)r3   b)r   c)r   from_tuplesr   r>   rB   r    ru   r%   r&   r'   rS   rT   rU   )r(   r  idxr   rv   rx   rW   s   &&     r   test_interp_multiIndex0TestSeriesInterpolateData.test_interp_multiIndexE  s     $$%CDAq"&&>-668Q
v0Oz55\; 65 555s   *C

C	c                   \         P                  ! R 4       \        ^\        P                  ^.. ROR7      pRp\         P
                  ! \        VR7      ;_uu_ 4        VP                  RR7       RRR4       R#   + '       g   i     R# ; i)r[   r9   z8krogh interpolation requires that the index be monotonicrP   kroghr8   N)r   r   r3   rS   rr   r   r>   rB   rT   rU   r%   r   s   &  r   test_interp_nonmono_raise3TestSeriesInterpolateData.test_interp_nonmono_raiseV  sY    G$Arvvq>3H]]:S11MMM) 2111s   A::B	r   c           	        \         P                  ! R 4       \        ^\        P                  ^.\        R^VR7      R7      pVR8X  dF   VP                  VR7      p\        . R	O\        R^VR7      R7      p\        P                  ! WE4       R# Rp\         P                  ! \        VR7      ;_uu_ 4        VP                  VR7       RRR4       R#   + '       g   i     R# ; i)
r[   1/1/2000r   tzr9   r   r8   r   rP   N)rh   rh   rp   )rS   rr   r   r>   rB   r   r%   r&   r'   rT   rU   )r(   r   tz_naive_fixturedfrx   rv   rW   s   &&&    r   test_interp_datetime640TestSeriesInterpolateData.test_interp_datetime64]  s    G$N*ZGW"X
 Y^^6^2F Q;KLH ""647Cz55f- 6555s   3CC!	c                   \        R ^RR7      p\        V4      p\        P                  V^&   Rp\        P
                  ! \        VR7      ;_uu_ 4        VP                  RR7       RRR4       R#   + '       g   i     R# ; i)z
2015-04-05z
US/Centralr#  r   rP   r   r8   N)r   r   r!   r"   rS   rT   rU   r%   )r(   dtir*   rW   s   &   r   #test_interp_pad_datetime64tz_values=TestSeriesInterpolateData.test_interp_pad_datetime64tz_valuesp  sY    q\BSkA3]]:S11OO5O) 2111s   A00B	c                t    \        . RO4      pVP                  ^R7      pTp\        P                  ! W#4       R# )rh   )r   Nrh   rl   rp   )r   r%   r&   r'   r   s   &   r   test_interp_limit_no_nans3TestSeriesInterpolateData.test_interp_limit_no_nansz  s/    ?#Q'
v0r   r   c                   \         P                  ! R 4       \        ^ ^\        P                  ^.4      pRp\         P
                  ! \        VR7      ;_uu_ 4        VP                  VR7       RRR4       R#   + '       g   i     R# ; i)r[   z6You must specify the order of the spline or polynomialrP   r8   Nr  )r(   r   r   rW   s   &&  r   test_no_order'TestSeriesInterpolateData.test_no_order  s\     	G$Aq"&&!$%F]]:S11MMM( 2111s   A77B	r   c                   \         P                  ! R 4       \        ^ ^\        P                  ^.4      pRp\         P
                  ! \        VR7      ;_uu_ 4        VP                  RVR7       RRR4       R#   + '       g   i     R# ; i)r[   z.order needs to be specified and greater than 0rP   r   r  Nr  )r(   r
   r   rW   s   &&  r   %test_interpolate_spline_invalid_order?TestSeriesInterpolateData.test_interpolate_spline_invalid_order  s\    G$Aq"&&!$%>]]:S11MMM7 2111s   A88B		c           	         \         P                  ! R 4       \        ^^\        P                  ^^\        P                  ^.4      pVP                  R^R7      p\        . RO4      p\        P                  ! W#4       R# )r[   r   r  Nrh   rl   rp   r   r   r   r   r   r   s   &   r   test_spline%TestSeriesInterpolateData.test_spline  s\    G$Aq"&&!Q23ha8=>
v0r   c           	     j   \         P                  ! R 4       \        ^^^^\        P                  ^\        P                  .4      pVP                  R^^R7      p\        . RO4      p\        P                  ! W#4       VP                  R^^ R7      p\        . RO4      p\        P                  ! WE4       R# )r[   r   )r   r
   extN)rh   rl   rp   r   r   r   r   r8  r   )r(   r   result3	expected3result1	expected1s   &     r   test_spline_extrapolate1TestSeriesInterpolateData.test_spline_extrapolate  s    G$Aq!Q26623--xqa-@>?	
w2--xqa-@>?	
w2r   c           	        \         P                  ! R 4       \        ^^\        P                  ^R\        P                  ^.4      pVP                  R^^ R7      ^,          VP                  R^R7      ^,          8w  g   Q hR# )r[   gffffff@r   )r   r
   r   r  N)rS   rr   r   r>   rB   r%   )r(   r   s   & r   test_spline_smooth,TestSeriesInterpolateData.test_spline_smooth  sl    G$Aq"&&!S"&&!45MMaM8;}}HA}6q9:	
:r   c                |   \         P                  ! R 4       \        \        P                  ! ^
4      ^,          RR7      p\        P
                  V\        P                  P                  ^4      P                  ^ ^	^4      &   VP                  R^R7      pVP                  R^R7      p\        P                  ! W#4       R# )r[   rA   r1   r   r  N)rS   rr   r   r>   r?   rB   r   r   integersr%   r&   r'   )r(   r   r?  r@  s   &   r   test_spline_interpolation3TestSeriesInterpolateData.test_spline_interpolation  s    G$299R=A%W58:"))


"
+
+Aq!
45--xq-9MMM;	
w2r   c                
   \        ^\        P                  ^.\        P                  ! . RO4      R7      pVP                  RR7      p\        . RO\        P                  ! . RO4      R7      p\        P                  ! W#4       \        ^\        P                  ^.\        P                  ! . RO4      R7      pVP                  RR7      p\        . RO\        P                  ! . RO4      R7      p\        P                  ! W#4       R# )	r3   r9   r=   r8   Nr  r.  )r3   r   r4   )rh   g(%?rp   )r   r>   rB   r!   to_timedeltar%   r&   r'   )r(   r&  rx   rv   s   &   r   test_interp_timedelta641TestSeriesInterpolateData.test_interp_timedelta64  s    QN"//)*DEv./1KL
v0 QN"//)*DEv..booi6PQ
v0r   c                <   \        R RRR7      p\        \        P                  P	                  ^4      P                  \        V4      4      VR7      p\        P                  VR&   VP                  RR7      pVP                  4       p\        P                  ! W44       R# )	r"  z	1/20/2000r   )freqr9   :NNr   r   r8   N)r   r   r>   r   r   r   r@   rB   r%   r&   r'   )r(   rngrF   rx   exps   &    r   %test_series_interpolate_method_values?TestSeriesInterpolateData.test_series_interpolate_method_values  sq    [s;BII))!,<<SXFcR&&3x0nn
v+r   c                <   \        R ^RR7      p\        . R	OV4      pVP                  V\        P                  ! ^R7      ,           4      P                  4       pVP                  V4      P                  RR7      p\        R ^RR7      p\        . R	OV4      pVP                  V\        P                  ! ^R7      ,           4      P                  4       pVP                  V4      P                  RR7      p\        P                  ! VP                  VP                  4       R# )
z1/1/201212D)r   rO  )daysr=   r8   12h)hoursN)r   ra      $   )r   r   appendr!   
DateOffsetsort_valuesrt   r%   r&   assert_numpy_array_equalr   )r(   r:   rF   rw   rQ  rx   s   &     r    test_series_interpolate_intraday:TestSeriesInterpolateData.test_series_interpolate_intraday  s    :qu=OU+LLA)>!>?KKM	jj#//v/>:qu=OU+LLQ)?!?@LLN	I&22&2A
##FMM3::>r   indz
2019-01-01startr   )rc  endc                   \         P                  ! ^ ^\        P                  ^.VR7      pVw  rEVR8X  d   \        P
                  ! R4       VR8X  dB   V^ ,          P                  ! R/ VB p\        . RO^ VR7      p\        P                  ! Wg4       R
# RV R2p\        P                  ! \        VR7      ;_uu_ 4        V^ ,          P                  ! RR	V/VB  R
R
R
4       R
#   + '       g   i     R
# ; i)r   r9   r}   r[   r7   namer:   z9Index column must be numeric or datetime type when using z_ method other than linear. Try setting a numeric or datetime index column before interpolating.rP   r   Nr   r   )r!   	DataFramer>   rB   rS   rr   r%   r   r&   r'   rT   rU   )	r(   r   ra  r&  r   r   rx   rv   expected_errors	   &&&      r   test_interp_non_timedelta_index9TestSeriesInterpolateData.test_interp_non_timedelta_index  s     \\1a+37+W(XU&&00F2#FH""64 !!!  z@@1!!::6: A@@@s   >C$$C5	c                   \         P                  ! R4       \        P                  ! ^^R7      p\        P                  ! ^ ^\
        P                  ^.VR7      pVw  rVVR	9   d3   VP                  \         P                  P                  V R2R7      4       V^ ,          P                  ! R
RV/VB p\        . RO^ VR7      p\        P                  ! Wx4       R# )z
Tests for non numerical index types  - object, period, timedelta
Note that all methods except time, index, nearest and values
are tested here.
r[   rb  r9   z2 interpolation is not supported for TimedeltaIndexr   r   rf  N>   r   r   r   r   )rS   rr   r!   timedelta_rangerh  r>   rB   applymarkermarkxfailr%   r   r&   r'   )	r(   r   r   ra  r&  r   r   rx   rv   s	   &&&      r    test_interpolate_timedelta_index:TestSeriesInterpolateData.test_interpolate_timedelta_index  s     	G$  q!4\\1a+37+&&!!$X%WX " 
 A"";&;F;.QcB
v0r   zascending, expected_valuesc                    \        ^
^	\        P                  ^^.. ROR7      pVP                  VR7      P	                  RR7      p\        W"\
        R7      p\        P                  ! WE4       R# )r<   )r   r:   )	ascendingr:   r8   )r   r:   r2   Nr<   r6   r^   r   r3   )r   r>   rB   
sort_indexr%   rA   r&   r'   )r(   rt  expected_valuesrF   rx   rv   s   &&&   r   test_interpolate_unsorted_index9TestSeriesInterpolateData.test_interpolate_unsorted_index  sX     "aA.6FG3??w?OUS
v0r   c                    \        . RO\        R7      pRp\        P                  ! \        VR7      ;_uu_ 4        VP                  RR7       RRR4       R#   + '       g   i     R# ; i)r  Nr1   z&Can not interpolate with method=asfreqrP   asfreqr8   )r  Nr  )r   r   rS   rT   rU   r%   )r(   r*   rW   s   &  r   test_interpolate_asfreq_raises8TestSeriesInterpolateData.test_interpolate_asfreq_raises  sB    %V46]]:S11OO8O, 2111s   AA(	c                8   \         P                  ! R 4       \        \        P                  ^ ^\        P                  ^\        P                  .4      pVP                  R^ R7      p\        \        P                  ^ ^^^^ .4      p\        P                  ! W#4       R# )r[   r   )r   
fill_valueNr   )r(   r*   rx   rv   s   &   r   test_interpolate_fill_value5TestSeriesInterpolateData.test_interpolate_fill_value"  sn    G$bffaBFFArvv67	a@2661aAq12
v0r   r   r   g      )r  r  r  rI   )r3   r   r^   r6   r<   ru  )D__name__
__module____qualname____firstlineno__rS   ro  rp  r.   rM   rX   ry   r   r   r   r   parametrizer   td
skip_if_nor   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r>   rB   ranger   r  r  r	  r  r  r  r  r'  r+  r/  r2  r5  r9  rA  rD  rH  rL  rR  r_  r!   period_rangeinterval_rangerj  rq  rx  r|  r  __static_attributes____classdictcell__)__classdict__s   @r   r   r   P   s$    [[IJ	6 K	640.1
<4<< [[LL<!4BMM'<R	
;;<,) [[LL<!4BMM'<R	
11111"1H1 [[Wr1g.@ /@@ [[-6J/KL; M;
11B-=^ [[ BFFBFFBFFArvvrvvN5,9
 BFFBFFBFFArvvrvvN5,'1E
 BFFBFFBFFArvvrvvN5,	:
 BFFBFFBFFArvvrvvN5,	7AF
 H5,	7AF
 a5,	7AF+	
:$;:$ [[ BFFBFFBFFArvvrvvN7L(;
 BFFBFFBFFArvvrvvN7L(GQG
 BFFBFFBFFArvvrvvN7L)<
 BFFBFFBFFArvvrvvN7L)WaH	
*$+*$12
11 * [[v||Dg8NOP<<* [[X	5'9:. ;.$*1 [[Xh'?@) A) [[Wr4C&@A8 B81	3
31	,? [[ OO,:A1-	
;;,1. [[$
 	!E+;#<=1	1-1 1r   r   )r7   r:   r   r   r   r   r   r   barycentricr  r   r   r   r   r}   r   r\   )r7   r   r   r   r   r  r  r   r   r   r   r}   r   r\   )numpyr>   rS   pandas.util._test_decoratorsutil_test_decoratorsr  pandasr!   r   r   r   r   r   pandas._testing_testingr&   fixturer   r   r   r   r   r   <module>r     ss      ) )    *	+*	 $	%$	X1 X1r   