From 633769b8d12ecd56917f894b338e928bc96a88ac Mon Sep 17 00:00:00 2001 From: Dave Date: Thu, 1 Feb 2024 10:53:31 -0800 Subject: [PATCH] Slight data updates --- notebooks/slifka.ipynb | 54 +++++++++++++++++++++++------------------- 1 file changed, 30 insertions(+), 24 deletions(-) diff --git a/notebooks/slifka.ipynb b/notebooks/slifka.ipynb index 923a569..ba82669 100644 --- a/notebooks/slifka.ipynb +++ b/notebooks/slifka.ipynb @@ -18,14 +18,14 @@ }, { "cell_type": "code", - "execution_count": 3, + "execution_count": 2, "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "100%|██████████| 18287/18287 [00:00<00:00, 952597.40it/s]" + "100%|██████████| 18287/18287 [00:00<00:00, 1235801.20it/s]" ] }, { @@ -121,14 +121,14 @@ }, { "cell_type": "code", - "execution_count": 4, + "execution_count": 3, "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "100%|██████████| 70659611/70659611 [04:29<00:00, 262293.44it/s]" + "100%|██████████| 70659611/70659611 [04:32<00:00, 259776.33it/s]" ] }, { @@ -233,14 +233,14 @@ }, { "cell_type": "code", - "execution_count": 5, + "execution_count": 4, "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "100%|██████████| 4643882/4643882 [00:05<00:00, 808163.79it/s]" + "100%|██████████| 4643882/4643882 [00:06<00:00, 691777.95it/s]" ] }, { @@ -280,14 +280,14 @@ }, { "cell_type": "code", - "execution_count": 11, + "execution_count": 5, "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "100%|██████████| 4643882/4643882 [00:09<00:00, 505675.05it/s]" + "100%|██████████| 4643882/4643882 [00:09<00:00, 495751.89it/s]\n" ] }, { @@ -296,13 +296,6 @@ "text": [ "Saved to ../data/weekly-contributions-2020.csv\n" ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "\n" - ] } ], "source": [ @@ -370,7 +363,7 @@ }, { "cell_type": "code", - "execution_count": 14, + "execution_count": 6, "metadata": {}, "outputs": [ { @@ -405,7 +398,7 @@ }, { "cell_type": "code", - "execution_count": 15, + "execution_count": 7, "metadata": {}, "outputs": [ { @@ -436,7 +429,7 @@ }, { "cell_type": "code", - "execution_count": 16, + "execution_count": 8, "metadata": {}, "outputs": [ { @@ -477,16 +470,16 @@ }, { "cell_type": "code", - "execution_count": 19, + "execution_count": 9, "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ - "100%|██████████| 1250295/1250295 [00:01<00:00, 1022021.36it/s]\n", - "100%|██████████| 1250295/1250295 [00:01<00:00, 1032787.78it/s]\n", - "100%|██████████| 1250295/1250295 [00:01<00:00, 1050511.00it/s]" + "100%|██████████| 1250295/1250295 [00:01<00:00, 810089.33it/s] \n", + "100%|██████████| 1250295/1250295 [00:01<00:00, 1051498.90it/s]\n", + "100%|██████████| 1250295/1250295 [00:01<00:00, 1054138.85it/s]" ] }, { @@ -495,7 +488,15 @@ "text": [ "Found 8 contributors who gave >= $100,000\n", "Found 332 contributors who gave >= $25,000\n", - "Found 7889 contributors who gave >= $5,000\n" + "Found 7889 contributors who gave >= $5,000\n", + "BELL, LEONARD (WOODBRIDGE, CT) gave $138,486.00 in 137 contributions\n", + "ROWE, KEVIN (SANTA FE, NM) gave $110,597.00 in 42 contributions\n", + "FINK, DAVID (LOS ANGELES, CA) gave $126,000.00 in 45 contributions\n", + "BEKENSTEIN, JOSHUA (WAYLAND, MA) gave $131,500.00 in 47 contributions\n", + "KLARMAN, SETH (BOSTON, MA) gave $129,800.00 in 47 contributions\n", + "SIMONS, NAT (BERKELEY, CA) gave $112,000.00 in 40 contributions\n", + "SRIKANT, RAM (CUPERTINO, CA) gave $117,500.00 in 43 contributions\n", + "RANDALL, GIOVANNA (NEW YORK, NY) gave $109,200.00 in 39 contributions\n" ] }, { @@ -531,7 +532,12 @@ "\n", "print(f\"Found {len(big_100k_contributors)} contributors who gave >= $100,000\")\n", "print(f\"Found {len(big_25k_contributors)} contributors who gave >= $25,000\")\n", - "print(f\"Found {len(big_5k_contributors)} contributors who gave >= $5,000\")" + "print(f\"Found {len(big_5k_contributors)} contributors who gave >= $5,000\")\n", + "\n", + "# Okay, I gotta know -- who *are* the biggest contributors?\n", + "for contributor, contributions in big_100k_contributors.items():\n", + " total = sum(amount_usd for _, _, amount_usd in contributions)\n", + " print(f\"{contributor.name} ({contributor.city}, {contributor.state}) gave ${total:,.2f} in {len(contributions)} contributions\")" ] } ],