Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup for partial borrowers notebook #14

Merged
merged 15 commits into from
May 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions .github/workflows/unit_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Setup Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: 3.9

Expand All @@ -38,5 +38,8 @@ jobs:
run: python -m pytest

# run treon on specific notebooks for now, since not all are passing!
- name: Run treon for notebooks
run: treon speculative_reading/HemingwayBorrowing.ipynb
- name: Run treon to check selected speculative_reading notebooks
run: treon speculative_reading/HemingwayBorrowing.ipynb speculative_reading/PartialBorrowers.ipynb

- name: Run treon to check selected missing_data notebooks
run: treon missing_data/ScoCalculateBorrowingCapacity.ipynb missing_data/ScoMissingBorrowingActivity.ipynb
2 changes: 1 addition & 1 deletion data/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ The files were generated by [identify_partial_borrowers.py](../speculative-readi

In the course of our research, we discovered long-duration borrow events (duration longer than a year) that had been incorrectly entered; these errors are present in the v1.2 datasets but corrections have been submitted to the Shakespeare and Company Project. Since these impact our estimates, we include a list overrides and a mechanism for applying them.

- longborrow_overrides.csv
- long_borrow_overrides.csv

#### incorporating long borrow corrections

Expand Down
2 changes: 1 addition & 1 deletion missing_data/ScoMissingBorrowingActivity.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
"outputs": [],
"source": [
"events_df, members_df, _, _ = load_initial_data()\n",
"events_df = process_events_data(events_df)"
"events_df = preprocess_events_data(events_df)"
]
},
{
Expand Down
5 changes: 3 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
pandas
pandas>=2.2
numpy
jupyter
datetimerange
prophet
altair
copia
vl-convert-python
vl-convert-python
seaborn
360 changes: 142 additions & 218 deletions speculative_reading/HemingwayBorrowing.ipynb

Large diffs are not rendered by default.

Loading
Loading