Skip to content

Commit 6aa2aae

Browse files
committed
2 parents 2d792ea + ba61e67 commit 6aa2aae

File tree

4 files changed

+43
-4
lines changed

4 files changed

+43
-4
lines changed

.github/workflows/get-metrics.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ def plot_usersXcountry(FOUNDATIONS_ID):
258258
# Plotting code
259259
fig = plt.figure(figsize=(10, 4))
260260
ax = plt.axes(projection=cartopy.crs.PlateCarree(), frameon=False)
261-
ax.set_title('Pythia Foundations Users by Country', fontsize=15)
261+
ax.set_title('All-Time Pythia Foundations Users by Country', fontsize=15)
262262

263263
shapefile = cartopy.io.shapereader.natural_earth(category='cultural', resolution='110m', name='admin_0_countries')
264264
reader = cartopy.io.shapereader.Reader(shapefile)

.github/workflows/write-metrics-md.py

+24-1
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,17 @@ def process_user_data(json_file, top_pages, this_year, map, md_file):
1515
user_data.pop('Now')
1616
f.write('\n\n')
1717

18+
# Intro description
19+
f.write(
20+
'This metrics page provides an overview of user activity collected by Google Analytics across the three pillars of Project Pythia: our portal which includes information about the project as well as our resource gallery, our Foundations book, and our Cookbooks gallery. Information is either all-time (from a pre-project start date of March 2020) or year-to-date as indicated and is updated nightly to provide real-time and automated insights into our engagement, impact, and audience reach. If you would like to request a different metrics analysis, timeframe, or view, please [open a GitHub issue](https://github.com/ProjectPythia/projectpythia.github.io/issues/new/choose).\n\n'
21+
)
22+
1823
# Markdown table
19-
headers = '| Project | Users |'
24+
f.write('## Table of Total Active Users by Project\n\n')
25+
f.write(
26+
'This table displays the total active users of our 3 Pythia projects over the life of Project Pythia. Google analytics defines active users as the number of unique people who have visited the site and met certain [engagement requirements](https://support.google.com/analytics/answer/9234069?sjid=8697784525616937194-NC). You can read more from the [GA4 "Understand User Metrics" documentation](https://support.google.com/analytics/answer/12253918?hl=en).\n\n'
27+
)
28+
headers = '| Project | All-Time Users |'
2029
separator = '| ' + ' | '.join(['-----'] * 2) + ' |'
2130
rows = []
2231
for key in user_data.keys():
@@ -26,8 +35,22 @@ def process_user_data(json_file, top_pages, this_year, map, md_file):
2635
f.write('\n\n')
2736

2837
# Add plots
38+
f.write('## Chart of Active Users by Project Since Year Start\n\n')
39+
f.write(
40+
'This line plot displays active users for our 3 Pythia projects (Portal in purple, Foundations in blue, and Cookbooks in salmon) since January 1st of the current year.\n\n'
41+
)
2942
f.write(f'![Users this Year]({this_year})\n\n')
43+
44+
f.write('## Chart of Top 5 Pages by Project\n\n')
45+
f.write(
46+
'This bar-chart displays the top 5 pages by project over the life of Project Pythia, as determined by screen page views. Screen page views refers to the number of times users viewed a page, including repeated visits. To learn more visit the [GA4 "API Dimensions & Metrics" page](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema).\n\n'
47+
)
3048
f.write(f'![Top Pages]({top_pages})\n\n')
49+
50+
f.write('## Map of Total Foundation Active Users by Country\n\n')
51+
f.write(
52+
'This map displays the number of active users per country for Pythia Foundations for the entire life of Project Pythia.\n\n'
53+
)
3154
f.write(f'![Users by Country]({map})\n\n')
3255

3356
f.close()

portal/index.md

+5-2
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,12 @@
77
:class: dark-banner
88
:::
99

10-
<span style="font-size: 2.6rem;">An education and training hub for the geoscientific Python community</span>
10+
<span style="font-size: 2.6rem;">An education and training hub for the geoscientific Python community</span><br>
1111

12-
<br><br>
12+
<a href="posts/cookoff2025-website.html" role="button" class="btn btn-light btn-lg" style="display: flex; align-items: center; font-weight: 600; text-decoration: none; background-color: #ccc; border: rgba(var(--spt-color-dark), 1);">
13+
Save the date for the 2025 Cook-off hackathon!
14+
</a>
15+
<br>
1316

1417
<a href="posts/new-cookbooks.html" role="button" class="btn btn-light btn-lg" style="display: flex; align-items: center; font-weight: 600; text-decoration: none; ">
1518
Round-up of new Cookbooks from our 2024 Cook-off hackathon!

portal/posts/cookoff2025-website.md

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
blogpost: true
3+
date: Feb 20, 2025
4+
author: Julia Kent
5+
tags: cook-off
6+
---
7+
8+
# Save the date for the 2025 Cook-off hackathon!
9+
10+
The 2025 Pythia Cookbook Cook-Off Hackathon will take place August
11+
5-8, at the NCAR Mesa Lab, located in Boulder, Colorado.
12+
13+
[The website for the event is live](https://projectpythia.org/pythia-cookoff-2025/). Registration is not open at this time.

0 commit comments

Comments
 (0)