Template talk:American transit ridership

Potential source of data
I wonder if the database (or reference links) could be updated to point to FTA data (total annual unlinked trips).
 * Each transit agency is assigned a five-digit identifier (for example, AC Transit is 90014)
 * Annual summary data is available in PDF format, linked to a URL that could be autogenerated:  where
 * YYYY = year (2014 – 2018) and
 * NNNNN = transit agency identifier, available from https://www.transit.dot.gov/ntd/data-product/2020-metrics

Cheers, Mliu92 (talk) 19:50, 21 June 2022 (UTC)


 * Huh. That's fascinating. Not sure how we'd work it into this template... but my brain is pretty fried from putting it all together. haha. RickyCourtney (talk) 21:43, 21 June 2022 (UTC)

How does this work?
I'm trying to add Detroit's daily ridership using this template, but can't figure out how to do that. I may just end up adding it traditionally. The APTA has weekday ridership as of Q3 2022. Criticalthinker (talk) 04:54, 1 February 2023 (UTC)

I added the templates to the Detroit Department of Transportation page to show you how it works. Thanks for letting us know about the Q3 numbers. We can add them in the next few days. RickyCourtney (talk) 05:09, 1 February 2023 (UTC)


 * I do not understand how to update the numbers. Where are the numbers being automatically pulled from, and why couldn't I just manually add those to the template? Criticalthinker (talk) 09:09, 1 February 2023 (UTC)
 * The template is manually updated, not automatically. You're free to help update the template (just click edit source, if you have the rights), but you can't just edit one agency. Hundreds of pages rely on this template, and they all rely on the information being updated at once. RickyCourtney (talk) 18:03, 1 February 2023 (UTC)
 * Heads-up; Q4 of 2022 numbers are out: https://www.apta.com/wp-content/uploads/2022-Q4-Ridership-APTA.pdf Criticalthinker (talk) 13:10, 29 March 2023 (UTC)
 * Thanks. I updated! RickyCourtney (talk) 19:30, 30 March 2023 (UTC)

Fails verification
I fixed an issue recently introduced to this template which caused an undefined reference error when used from Manatee County Area Transit. Now, the template doesn't generate an undefined reference. However, the reference it does generate does not support verification for the number given for ridership in that system. Was my fix incorrect? Is there some way to get this template working correctly? Has anyone verified the numbers it produces against the references it generates for each of the systems it claims to support? I'm wondering how serious the quality problem is here. -- Mikeblas (talk) 23:18, 15 April 2023 (UTC)

Formatnum-friendly output
Would it be possible to have an output without commas so that annual figures can be rounded automatically using format price or the formatnum magic words? As it stands, it's awkward and may run afoul of MOS:LARGENUM.  Sounder Bruce  06:26, 30 June 2023 (UTC)


 * Hey Bruce! I’ve done something like that on an as needed basis for some entries, for example, Los Angeles and New York City. Feel free to change any of the entries to a similar format. Making a separate output is beyond my knowledge of template programming. -- RickyCourtney (talk) 15:44, 4 July 2023 (UTC)

The NYC data is obviously very false
No, NYC ridership did not eclipse 2019 ridership in 2022-ridership barely was over 1 billion. I have no idea where this number came from, and it is incredibly misleading. Kew Gardens 613 (talk) 20:31, 26 July 2023 (UTC)
 * @Kew Gardens 613, the number comes from page 27 of this document. Though I too am confused about the figures. MTA New York City Transit heavy rail (excluding the SIR) did not have 1.7 billion entries in 2022. Perhaps APTA is counting transfers as separate rides, so if someone transferred once, that might be counted as two rides. But again, I don't know. – Epicgenius (talk) 23:51, 26 July 2023 (UTC)
 * @Kew Gardens 613, @Epicgenius: The APTA site says that Passengers are counted each time they board vehicles no matter how many vehicles they use to travel from their origin to their destination, so Epicgenius seems right that they count transfers individually. Conversely, the MTA says We do not include […] Passengers who transfer from other subway lines, with the exception of out-of-system transfers. Tl;dr: APTA is reporting unlinked trips and the MTA is reporting linked trips. Ideally this should be made clear somewhere. Shells-shells (talk) 04:18, 3 August 2023 (UTC)

template broken on Sonoma–Marin Area Rail Transit article
The second instance of this template on Sonoma–Marin Area Rail Transit is broken. it returns Expression error: Unrecognized word "n". -MJ (talk) 23:44, 10 December 2023 (UTC)


 * Looks like there was a typo (an errant “n”) in the formula. It’s been corrected now. Verified the warning is gone. RickyCourtney (talk) 23:48, 10 December 2023 (UTC)