-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdividens-000.py
More file actions
42 lines (36 loc) · 1.23 KB
/
Copy pathdividens-000.py
File metadata and controls
42 lines (36 loc) · 1.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
""" Tool_Finance - Récupérer les dividens
"""
import yfinance
#ticker = "AM.PA" # DASSAULT AVIATION
ticker = "BEN.PA" # BENETEAU
stock = yfinance.Ticker( ticker )
start_date = "2000-01-01"
end_date = "2025-01-01"
dividends_period = stock.history( start=start_date, end=end_date ).loc[:, 'Dividends']
dividends_period = stock.dividends # tous les dividendes
print( dividends_period )
# Date
# 2000-05-09 00:00:00+02:00 0.50
# 2001-05-10 00:00:00+02:00 0.62
# 2002-05-10 00:00:00+02:00 0.65
# 2003-05-28 00:00:00+02:00 0.83
# 2004-05-10 00:00:00+02:00 0.77
# 2005-05-02 00:00:00+02:00 0.77
# 2006-05-02 00:00:00+02:00 0.99
# 2007-05-09 00:00:00+02:00 0.74
# 2008-04-29 00:00:00+02:00 1.06
# 2009-05-15 00:00:00+02:00 0.58
# 2010-05-24 00:00:00+02:00 0.88
# 2011-05-23 00:00:00+02:00 1.07
# 2012-05-29 00:00:00+02:00 0.85
# 2013-05-20 00:00:00+02:00 0.93
# 2014-05-21 00:00:00+02:00 0.89
# 2015-05-28 00:00:00+02:00 1.00
# 2016-05-30 00:00:00+02:00 1.21
# 2017-05-29 00:00:00+02:00 1.21
# 2018-06-01 00:00:00+02:00 1.53
# 2019-05-22 00:00:00+02:00 2.12
# 2021-05-18 00:00:00+02:00 1.23
# 2022-05-23 00:00:00+02:00 2.49
# 2023-05-19 00:00:00+02:00 3.00
# 2024-05-20 00:00:00+02:00 3.37