Repository navigation
Add measles and EPICC, CRAN download badges, and fix the dashboard metrics - #66
Merged
Merged
Conversation
- data/measles.yml: R package with measles ABMs built on epiworldR (UofUEpiBio/measles), published on CRAN. - data/epicc.yml: EPidemiological Cost Calculator, a Streamlit app for comparing the cost of outbreak scenarios (EpiForeSITE/epicc). README.qmd now binds the project files with fill = TRUE so that optional fields (such as the cran_name introduced in the next commit) do not break the render. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
CRAN: - New CRAN column with version and download badges (grand total and last month) for projects published on CRAN. - A project is matched to a CRAN package through the optional cran_name field in its YAML file, or, when absent, by trying the repository name and the first word of tool_name against the CRAN index and accepting a hit only when the package metadata links back to the same GitHub owner or repository. Seven projects match today. - epiworld declares cran_name: epiworldR, since its CRAN artifact lives in a different repository. Metrics: - Contributors and open PRs were counted with length() on a parsed data frame, which returns the number of columns: every repository reported 20 contributors and 36 open PRs. - Open issues came from open_issues_count, which includes pull requests. PRs are now discounted so the number matches the issues badge. - Commit totals came from the search API, which is heavily rate limited and reports 0 for unindexed repositories (epiworld showed 0 commits, now 658). All collection sizes now come from the last page number of the Link header: one request, exact count. - A failed request reports N/A instead of 0. - Rows had one more cell than the header. - commits_data was assigned to the global environment with <<-. Presentation: - Projects are sorted by most recent commit and carry an activity marker (green: 90 days, yellow: a year, white: older or unknown). - A summary of activity, CRAN releases, and open issues/PRs sits above the table. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
…AN badges - data/epiworldrcalibrate.yml: pre-trained ML calibration for epiworldR ABMs (sima-njf/epiworldRcalibrate), published on CRAN. - rbranding pointed at EpiForeSITE/branding-package, which has since been renamed to EpiForeSITE/rbranding; its docs link moved with it. The package name is now declared explicitly rather than inferred. - The CRAN badges move out of their own column and sit under the repository link, on a single line. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Member
Author
|
Follow-up pushed in
The dashboard now tracks 24 projects, 8 of them on CRAN. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this does
1. Two projects added to
data/measles: Measles Epidemiological ModelsDESCRIPTION. On CRAN.EPICC: Epidemiological Cost Calculatordocs/stories.md.Two things worth a second opinion from the maintainers:
epicchas no license file, solicenseis.na.character. Worth adding one to the repo.measles: George;epicc: Edward Wang and George). Correct them if that is not who should be listed.2. CRAN badges in the dashboard
New CRAN column with version, grand-total downloads, and downloads/month badges. Seven projects match today:
epitraxr,epiworldR,linkeR,measles,pomp,quadkeyr,rbranding.How a project is matched to a CRAN package:
cran_namefield in the project's YAML wins. Use it when the names differ (epiworldnow declarescran_name: epiworldR, since its CRAN artifact lives in another repo), or set it tonoto skip the lookup entirely.tool_nameare checked against the CRAN index, and a hit is only accepted when the package's CRAN metadata (URLorBugReports) points back at the same GitHub owner or repository.Step 2 is what keeps a project from picking up the badges of an unrelated CRAN package that happens to share its name, and it still catches the cases where repo and package names have drifted apart (
quadkeyrmoved to rOpenSci,rbrandinglives inbranding-package).3. Bugs fixed along the way
The numbers in the dashboard were wrong, in ways that were invisible because most of them were never printed:
length()on a parsed data frame, which returns the column count. Every repository was recorded as having 20 contributors and 36 open PRs. Only the avatars were displayed, so this stayed hidden.open_issues_count, which GitHub defines as issues plus pull requests. PRs are now discounted, so the number agrees with the issues badge next to it.0for repositories it has not indexed.epiworldwas reported as having 0 commits; it has 658. All collection sizes now come from the last page number in theLinkheader: one request, exact count, no fallback chain.N/Ainstead of0.commits_data <<-was writing to the global environment.4. Presentation
Notes for reviewers
README.md,profiles.md, anddata/software.xlsxare not in this PR. They are generated by the Build README workflow, which will regenerate them on merge.README.qmdnow usesrbindlist(fill = TRUE)so the optionalcran_namefield does not break that render.available.packages()(one call per run) pluscrandb.r-pkg.orgfor the handful of candidate hits.Suggestions not included here
epiworldpy), which the CRAN code is shaped to accommodate.vaccine-equity-modelandmultigroup-vaccineare duplicate entries for what looks like the same project, under the same name, with identical metrics. One of them should probably go.Fernandez-Lab-WSU/geocovid_appreturns 404 to the API, so GeoCovid shows no data. It looks like the repo was moved, renamed, or made private.data/*.ymlfiles mostly lack a trailing newline, which makes the script emit ~40 "incomplete final line" warnings per run.🤖 Generated with Claude Code