This Library accept pandas dataframe, date_column and optional end date If end date is not provide, current today will be use internally by the library
Project description
This package "week by Week"
is attempt to have Python library that
- Generate week range from pandas dataframe from the first data point date to the current or a given date
- Group pandas row into weekly base on the date/timestamp column
Release Log
- week-by-week version 3.14.0a0 (Released, June 21, 2022) Weekfly Dataframe capability added
- week-by-week version 3.14.0 (Released, June 20, 2022)
Usage after installation
from week_by_week import WeekRange
Instantiate the class
get_weeks = WeekRange(df, 'timestamp','2022/06/01', WK_start='sun')
Required parameter are: 1. df -- pandas dataframe 2. timestamp -- date columnin your df 3. WK_start change between 'Mon' to 'Sun' Optional parameter: 1. end_date
call getAllweeks()`` method to retrieve all weeks weeks = get_weeks.getAllweeks()```
And to retrieve data splitted into week range,
invoke getWeekData()
print(get_weeks.getWeekData())
To retrieved Pandas Dataframe splited into week invoke the following interface method
for week in get_weeks.retunpandasDF():
print(week)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file week_by_week-3.14.0b0.tar.gz.
File metadata
- Download URL: week_by_week-3.14.0b0.tar.gz
- Upload date:
- Size: 3.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.13 CPython/3.10.4 Linux/5.13.0-44-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
05346fa64601ff121229832176c3735314f59e9abb5fcb3a8c18f8c2f3e42667
|
|
| MD5 |
bf69805538321787dd2483290a631c38
|
|
| BLAKE2b-256 |
1bf0510722ec1979fbd3f5879d09232fb3a5f4b4d47b2184553b31934349842c
|
File details
Details for the file week_by_week-3.14.0b0-py3-none-any.whl.
File metadata
- Download URL: week_by_week-3.14.0b0-py3-none-any.whl
- Upload date:
- Size: 3.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.13 CPython/3.10.4 Linux/5.13.0-44-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bdc7c70dac604cbe5f619977f928a632786d572d5e7c412d837d4f0de6d2e858
|
|
| MD5 |
a52d465797079662759cdbf2825dad6a
|
|
| BLAKE2b-256 |
fd8f49c93c2d92d22fa8eb9e97a2b8b2050487b5bee07bbc6fd656713043ddbf
|