pandas.Period.week#

Period.week#

Get the week of the year on the given Period.

Returns:
int

See also

Period.dayofweek

Get the day component of the Period.

Period.weekday

Get the day component of the Period.

Examples

>>> p = pd.Period("2018年03月11日", "h")
>>> p.week
10
>>> p = pd.Period("2018年02月01日", "D")
>>> p.week
5
>>> p = pd.Period("2018年01月06日", "D")
>>> p.week
1