《Slides Dev Web》 08 . RSS08.RSS 19 décembre 2023 Développement web il3 Really Simple Syndication HE-Arc (DGR) 2022 Syndication • Principe de vendre un contenu à plusieurs médias • Dans les journaux : dépêches, bandes dessinées0 码力 | 7 页 | 52.98 KB | 1 年前3
Monads in Modern C++03: template04: struct vector 05: { 06: // ... 07: template 08: vector transform(function f) 09: { 10: 11: 12: 13: 03: template 04: struct vector 05: { 06: // ... 07: template 08: vector transform(function f) 09: { 10: vector out; 11: 12: 13: 03: template 04: struct vector 05: { 06: // ... 07: template 08: vector transform(function f) 09: { 10: vector out; 11: for 0 码力 | 94 页 | 4.56 MB | 6 月前3
pandas: powerful Python data analysis toolkit - 0.17.0In [22]: p = pd.Period('2015-08-01', freq='3D') 8 Chapter 1. What’s New pandas: powerful Python data analysis toolkit, Release 0.17.0 In [23]: p Out[23]: Period('2015-08-01', '3D') In [24]: p + 1 Out[24]: Out[24]: Period('2015-08-04', '3D') In [25]: p - 2 Out[25]: Period('2015-07-26', '3D') In [26]: p.to_timestamp() Out[26]: Timestamp('2015-08-01 00:00:00') In [27]: p.to_timestamp(how='E') Out[27]: T Timestamp('2015-08-03 00:00:00') You can use the multiplied freq in PeriodIndex and period_range. In [28]: idx = pd.period_range('2015-08-01', periods=4, freq='2D') In [29]: idx Out[29]: PeriodIndex(['2015-08-01'0 码力 | 1787 页 | 10.76 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.20.32000-01-04 NaN NaN NaN 2000-01-05 NaN NaN NaN 2000-01-06 NaN NaN NaN 2000-01-07 NaN NaN NaN 2000-01-08 0.901805 1.171216 0.520260 2000-01-09 -1.197071 -1.066969 -0.303421 2000-01-10 -0.858447 0.306996 NaN NaN NaN NaN NaN 2000-01-06 NaN NaN NaN NaN NaN NaN 2000-01-07 NaN NaN NaN NaN NaN NaN 2000-01-08 0.901805 2.098877 1.171216 2.242573 0.520260 1.803042 2000-01-09 1.197071 0.000000 1.066969 0.004388 foo 2016-04-05 0.640880 0.126205 2016-04-06 0.171465 0.737086 2016-04-07 0.127029 0.369650 2016-04-08 0.604334 0.103104 2016-04-09 0.802374 0.945553 Previous Behavior: In [2]: df.rolling(12).corr()0 码力 | 2045 页 | 9.18 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.20.22000-01-04 NaN NaN NaN 2000-01-05 NaN NaN NaN 2000-01-06 NaN NaN NaN 2000-01-07 NaN NaN NaN 2000-01-08 0.901805 1.171216 0.520260 2000-01-09 -1.197071 -1.066969 -0.303421 2000-01-10 -0.858447 0.306996 NaN NaN NaN NaN NaN 2000-01-06 NaN NaN NaN NaN NaN NaN 2000-01-07 NaN NaN NaN NaN NaN NaN 2000-01-08 0.901805 2.098877 1.171216 2.242573 0.520260 1.803042 2000-01-09 1.197071 0.000000 1.066969 0.004388 foo 2016-04-05 0.640880 0.126205 2016-04-06 0.171465 0.737086 2016-04-07 0.127029 0.369650 2016-04-08 0.604334 0.103104 2016-04-09 0.802374 0.945553 1.2. v0.20.1 (May 5, 2017) 29 pandas: powerful Python0 码力 | 1907 页 | 7.83 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.21.12000-01-04 NaN NaN NaN 2000-01-05 NaN NaN NaN 2000-01-06 NaN NaN NaN 2000-01-07 NaN NaN NaN 2000-01-08 1.667624 1.619575 -0.948507 2000-01-09 -0.360596 1.412609 -0.398833 2000-01-10 -2.429301 -0.645124 NaN NaN NaN NaN NaN 2000-01-06 NaN NaN NaN NaN NaN NaN 2000-01-07 NaN NaN NaN NaN NaN NaN 2000-01-08 1.667624 4.096925 1.619575 3.254838 0.948507 0.045502 2000-01-09 0.360596 2.068705 1.412609 3.047871 foo 2016-04-05 0.640880 0.126205 2016-04-06 0.171465 0.737086 2016-04-07 0.127029 0.369650 2016-04-08 0.604334 0.103104 2016-04-09 0.802374 0.945553 Previous Behavior: In [2]: df.rolling(12).corr()0 码力 | 2207 页 | 8.59 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.19.1In [70]: pd.Timestamp(year=2012, month=1, day=1, hour=8, minute=30) Out[70]: Timestamp('2012-01-01 08:30:00') • The .resample() function now accepts a on= or level= parameter for resampling on a datetimelike integer dtype: Previous behavior: In [1]: pi = pd.PeriodIndex(['2016-08-01'], freq='D') In [2]: pi Out[2]: PeriodIndex(['2016-08-01'], dtype='int64', freq='D') In [3]: pd.api.types.is_integer_dtype(pi) dtype('int64') New behavior: In [117]: pi = pd.PeriodIndex(['2016-08-01'], freq='D') In [118]: pi Out[118]: PeriodIndex(['2016-08-01'], dtype='period[D]', freq='D') In [119]: pd.api.types.is_integer_dtype(pi)0 码力 | 1943 页 | 12.06 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.19.0In [70]: pd.Timestamp(year=2012, month=1, day=1, hour=8, minute=30) Out[70]: Timestamp('2012-01-01 08:30:00') • The .resample() function now accepts a on= or level= parameter for resampling on a datetimelike integer dtype: Previous behavior: In [1]: pi = pd.PeriodIndex(['2016-08-01'], freq='D') In [2]: pi Out[2]: PeriodIndex(['2016-08-01'], dtype='int64', freq='D') In [3]: pd.api.types.is_integer_dtype(pi) dtype('int64') New behavior: In [117]: pi = pd.PeriodIndex(['2016-08-01'], freq='D') In [118]: pi Out[118]: PeriodIndex(['2016-08-01'], dtype='period[D]', freq='D') In [119]: pd.api.types.is_integer_dtype(pi)0 码力 | 1937 页 | 12.03 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.24.0date_range('2001-01-01', periods=2, freq='7D') In [10]: dti + pd.Index([1, 2]) Out[10]: DatetimeIndex(['2001-01-08', '2001-01-22'], dtype='datetime64[ns]', ˓→freq=None) New Behavior: In [102]: ts = pd.Timestamp('1994-05-06 freq='7D') In [107]: dti + pd.Index([1 * dti.freq, 2 * dti.freq]) Out[107]: DatetimeIndex(['2001-01-08', '2001-01-22'], dtype='datetime64[ns]', ˓→freq=None) 1.4. Deprecations 31 pandas: powerful Python (continued from previous page) In [113]: ts Out[113]: 2012-03-06 0.600390 2012-03-07 -0.296105 2012-03-08 -0.645278 2012-03-09 -0.229840 2012-03-10 -0.448017 Freq: D, dtype: float64 In [114]: ts_utc =0 码力 | 2973 页 | 9.90 MB | 1 年前3
pandas: powerful Python data analysis toolkit - 0.25(continued from previous page) In [113]: ts Out[113]: 2012-03-06 0.198218 2012-03-07 -0.649384 2012-03-08 0.743513 2012-03-09 -0.541289 2012-03-10 -0.594013 Freq: D, dtype: float64 In [114]: ts_utc = ts [115]: ts_utc Out[115]: 2012-03-06 00:00:00+00:00 0.198218 2012-03-07 00:00:00+00:00 -0.649384 2012-03-08 00:00:00+00:00 0.743513 2012-03-09 00:00:00+00:00 -0.541289 2012-03-10 00:00:00+00:00 -0.594013 19:00:00-05:00 0.198218 2012-03-06 19:00:00-05:00 -0.649384 2012-03-07 19:00:00-05:00 0.743513 2012-03-08 19:00:00-05:00 -0.541289 2012-03-09 19:00:00-05:00 -0.594013 Freq: D, dtype: float64 Converting0 码力 | 698 页 | 4.91 MB | 1 年前3
共 1000 条
- 1
- 2
- 3
- 4
- 5
- 6
- 100













