Although the results of the Pearson's and Spearman's tests do confirm my initial theory that younger CitiBike riders tend to ride for longer, the results of the two tests cannot be taken at face value. Although the ride duration averages were calculated based on over 2 million individual CitiBike rides, each test was ultimately performed on only 32 data points. The results therefore are less powerful.
One way to strengthen the analysis would be to incorporate more data both into the initial ride duration averaging and the final analysis of average rides by rider birth year. In the following cells, I create a second dataframe that includes rides from CitiBike riders of all genders and ages. I then calculate the average ride duration for each birth year and perform Pearson's and Spearman's statistical tests.