Bike Forums

Bike Forums (https://www.bikeforums.net/forum.php)
-   Road Cycling (https://www.bikeforums.net/road-cycling/)
-   -   Average elevation gain (https://www.bikeforums.net/road-cycling/1074285-average-elevation-gain.html)

Koyote 10-01-23 09:10 PM


Originally Posted by spelger (Post 23031305)
of course, all my rides start and end at the same place. but that is not really what this thread is about, although the title is misleading. but i think you already know that.

Well, I'm not sure what you're getting at. This statement has me confused:


Originally Posted by spelger (Post 23031212)
i still question the usefulness of this metric. i often read that 100 ft/mi is some sort of benchmark. but that is not quite a 2% grade. i doubt most here are riding 2% grades from start to finish. most of mine are 5+%. maybe a better metric would be average grade for distances with grades > 0%?

100ft/mi is a benchmark (albeit arbitrary), yes...And it's an average. A typical ride with that ratio of climbing might have few (or no) passages that are exactly 2% grade. If you calculate the average grade of ONLY sections that have grades >0%, then you might do a rather flat fifty mile ride which includes only one short stretch of 5% climbing -- which says very little about the climbing (or difficulty) of the ride in its entirety.

Of course, not all 100ft/mi rides are equal, either: I've done some of the biggest hill climb races in Colorado, which involve far more than 100ft/mi -- some over double that ratio. And yet, some races out in WV and PA which have around 100ft/mi (give or take) were waaaay harder, because the climbs were steeper (albeit shorter, and with descents). Much harder to modulate your aerobic effort.


Originally Posted by spelger (Post 23031305)
yes, i agree, very unlikely without to compute in your head or with a simple calculation. piece of cake with a small program though. spreadsheet...? yeah, no way.

Again, I know of no program for doing this...But yeah. Spreadsheets are useful, but they won't do that.

mschwett 10-01-23 09:35 PM


Originally Posted by Koyote (Post 23031284)
…I think that would be virtually impossible to calculate for a ride of any reasonable length, unless there is some software out there with which I'm not familiar. (And no, a spreadsheet would be of no help.)

nah, given the nature of the XML schema for bike rides, you could pretty easily do this. break the tags onto columns, one row per trackpoint, a simple if statement referencing the elevation and distance of the prior and current row gives you the grade between those two points. then another statement discarding that point if the grade is less than some selected percentage. weight the remaining grades by the distance they represent, and there you go. you could make a histogram or averages or whatever you want.

Koyote 10-01-23 09:45 PM


Originally Posted by mschwett (Post 23031340)
nah, given the nature of the XML schema for bike rides, you could pretty easily do this. break the tags onto columns, one row per trackpoint, a simple if statement referencing the elevation and distance of the prior and current row gives you the grade between those two points. then another statement discarding that point if the grade is less than some selected percentage. weight the remaining grades by the distance they represent, and there you go. you could make a histogram or averages or whatever you want.

Show us an example from a strava or ridewithgps file, and let us know how long it takes you to create it.

Serious request. I'm genuinely curious.

mschwett 10-01-23 09:54 PM


Originally Posted by Koyote (Post 23031347)
Show us an example from a strava or ridewithgps file, and let us know how long it takes you to create it.

Serious request. I'm genuinely curious.

sure, I’ll do it tomorrow. both sheets and excel are pretty good for ghetto-parsing XML.

mschwett 10-02-23 11:52 AM


Originally Posted by Koyote (Post 23031347)
Show us an example from a strava or ridewithgps file, and let us know how long it takes you to create it.

Serious request. I'm genuinely curious.

strava -> export to gpx.

import gpx (as XML) into excel. depending on your data source, some of the elements of the scheme may not be recognized - i ignored errors related to additional data like power balance and so on. from XML source tab, drop lat, lon, and elevation into columns. fill those columns with the data.

this scheme didn't have distance, so i added the formula to calculate distance from latitude and longitude into column F, returns meters. column G is the change in elevation. column I is the change in elevation over the distance. column K is the change in elevation if it's greater than 3%, and 0 otherwise. column L is the distance if the change in elevation is greater than 3%, and 0 otherwise. K1 and L1 are the sum of those columns, and N1 (bolded number) is the percentage slope in aggregate. this is about what i'd expect - most roads in the bay area are graded to around 6% when they're going uphill. this ride was 64 miles and 6,127 feet of climbing. if you just used those numbers and assumed you went up half the time, then down half the time, you'd get 3.6%, obviously wrong.

this took about 5 minutes plus about 5 minutes refreshing my memory on how to fill the XML data into the columns. it would take about one minute per ride now.

https://cimg9.ibsrv.net/gimg/bikefor...de9f8adb67.jpg



strava summary:
https://cimg4.ibsrv.net/gimg/bikefor...ef2184cbc2.jpg

https://cimg7.ibsrv.net/gimg/bikefor...29039e9426.jpg

Koyote 10-02-23 12:53 PM


Originally Posted by mschwett (Post 23031775)
strava -> export to gpx.

import gpx (as XML) into excel. depending on your data source, some of the elements of the scheme may not be recognized - i ignored errors related to additional data like power balance and so on. from XML source tab, drop lat, lon, and elevation into columns. fill those columns with the data.

this scheme didn't have distance, so i added the formula to calculate distance from latitude and longitude into column F, returns meters. column G is the change in elevation. column I is the change in elevation over the distance. column K is the change in elevation if it's greater than 3%, and 0 otherwise. column L is the distance if the change in elevation is greater than 3%, and 0 otherwise. K1 and L1 are the sum of those columns, and N1 (bolded number) is the percentage slope in aggregate. this is about what i'd expect - most roads in the bay area are graded to around 6% when they're going uphill. this ride was 64 miles and 6,127 feet of climbing. if you just used those numbers and assumed you went up half the time, then down half the time, you'd get 3.6%, obviously wrong.

this took about 5 minutes plus about 5 minutes refreshing my memory on how to fill the XML data into the columns. it would take about one minute per ride now.

Thanks, that is very interesting! I wonder if there is some way to automate it?

I've never worked with that sort of data in excel before, so was curious how you'd do it. Looks like you and rsbob were right, and I was wrong!

Relating to the original question, this might be a more appealing measure for some riders, and might more accurately depict the difficulty of certain rides. I once did this event, which is all about the climbs -- most of which are over 20%, with one hitting a 37% grade. The riding in-between hills is pretty irrelevant, so an average of the actual climbing would be an interesting number. But I do think that most riders will stick to the ft/mi metric for the entire ride.

spelger 10-02-23 01:33 PM

so although going by the more traditional feet/mi metric this ride comes in at less than 100 ft/mi or less than 2%. the 6.7% that you calculated seems like it makes more sense to me. now i just have to let that soak in. i use strava as a ride repository but then pull it all down to my PC so i think i'll add this to my app and see how much i like this metric.

RChung 10-02-23 01:56 PM


Originally Posted by mschwett (Post 23031775)
strava -> export to gpx.

Very nice. Years ago I used to do something similar but with power and speed data: I'd calculate the virtual slope based on speed and power and then use that to get the "weighted slope" conditional on the slope > x where x is a small positive number like 1%. This is virtual slope, so it includes wind -- a headwind increases virtual slope while a tailwind diminishes it. Conditioning on x>0 removes flats and downhills, mostly: the mostly is cuz of headwinds. I thought this might be better indication of how "tough" a ride was; the same route on a calm vs. windy day would have a different virtual elevation gain. I thought a little bit about the proportion of Joules allocated to virtual climbing to total Joules used during the ride but I sorta gave up after that cuz no one understood back then what I meant by virtual elevation.

mschwett 10-02-23 02:57 PM


Originally Posted by RChung (Post 23031912)
Very nice. Years ago I used to do something similar but with power and speed data: I'd calculate the virtual slope based on speed and power and then use that to get the "weighted slope" conditional on the slope > x where x is a small positive number like 1%. This is virtual slope, so it includes wind -- a headwind increases virtual slope while a tailwind diminishes it. Conditioning on x>0 removes flats and downhills, mostly: the mostly is cuz of headwinds. I thought this might be better indication of how "tough" a ride was; the same route on a calm vs. windy day would have a different virtual elevation gain. I thought a little bit about the proportion of Joules allocated to virtual climbing to total Joules used during the ride but I sorta gave up after that cuz no one understood back then what I meant by virtual elevation.

i feel like if i did this it would illustrate the bad life choices i’ve made which cause some rides to be uphill and/or into the wind for 90% of their duration 😂😂 … virtual slope always greater than zero!

spelger 10-02-23 03:02 PM

the difficulty here is knowing the wind direction. RChung, you don't mention location but here in Reno the wind blows every which direction possible. i don't fault the NOAA but their data is just not accurate.

mschwett 10-02-23 03:08 PM


Originally Posted by spelger (Post 23031980)
the difficulty here is knowing the wind direction. RChung, you don't mention location but here in Reno the wind blows every which direction possible. i don't fault the NOAA but their data is just not accurate.

for the method he mentioned you don’t need to know the wind direction - the relationship is between power and speed, it’s either “harder” or “easier” depending on that relationship…

RChung 10-02-23 04:46 PM


Originally Posted by mschwett (Post 23031985)
for the method he mentioned you don’t need to know the wind direction - the relationship is between power and speed, it’s either “harder” or “easier” depending on that relationship…

Yup. I was always confused by rides classified by average elevation gain per mile -- I was more concerned by the length and difficulty of the hardest climbs during the ride, not the average. Eventually I realized that with power and speed data, I could tell when I was putting out a lot of power for not much speed (and vice versa) and that was a closer measure of difficulty, and it didn't matter so much whether it was hard because of the slope or the wind: they scale differently, but they're both hard so I converted winds into "equivalent" elevation. I also looked at converting slope into wind, but the pattern there was harder to discern.

spelger 10-02-23 06:54 PM


Originally Posted by mschwett (Post 23031985)
for the method he mentioned you don’t need to know the wind direction - the relationship is between power and speed, it’s either “harder” or “easier” depending on that relationship…


Originally Posted by RChung (Post 23032104)
Yup. I was always confused by rides classified by average elevation gain per mile -- I was more concerned by the length and difficulty of the hardest climbs during the ride, not the average. Eventually I realized that with power and speed data, I could tell when I was putting out a lot of power for not much speed (and vice versa) and that was a closer measure of difficulty, and it didn't matter so much whether it was hard because of the slope or the wind: they scale differently, but they're both hard so I converted winds into "equivalent" elevation. I also looked at converting slope into wind, but the pattern there was harder to discern.

At least we are on teh same page as noted in my post #72. i think i didn't read what you wrote quite well though, in one eye and out the other (so to speak). i aslo don't have a PM so for me to make a virtual slope calculation would be quite futile.

this particular metric seems more useful but i suppose that is what TSS is for. i wonder, does TSS go down as a ride accumulates distance at an easy pace or more descents? or maybe it just does not increase. thinking out loud, not looking for an answer.

RChung 10-03-23 10:17 AM


Originally Posted by spelger (Post 23032232)
i wonder, does TSS go down as a ride accumulates distance at an easy pace or more descents? or maybe it just does not increase. thinking out loud, not looking for an answer.

I believe that if you add some zero power time at the end of a ride (for example, if your head unit somehow continues to record zeroes after the end of your ride), the "new" TSS for the "new" ride duration will continue to increase. I mentioned this to Andy Coggan 20 years ago when he first proposed TSS and he said, "make sure your head unit doesn't do that." But, as has been pointed out to me recently, the things and behaviors I find odd most people don't.

terrymorse 10-03-23 11:24 AM

Sometimes, average elevation gain does not tell the story. At least not the important part.

Here's an example of a route that feels much harder than the average would indicate. It's 51 miles, but it has only about 63 feet per mile.

It has several short but steep climbs that beat mightily on my legs. The final climb has an extended section at 15%, at which point I find myself uttering curse words to nobody in particular.

I'm resolved to repeat this route until it becomes easy (or at least easier).

https://cimg5.ibsrv.net/gimg/bikefor...4d10b1ceff.png
Steep roads of Los Gatos 51

wheelreason 10-04-23 12:03 PM

Our usual 40-60 mile rides have 2000 feet or so, but it's all annoying rollers and short humps that just break up rhythm more than anything.

Sierra_rider 10-06-23 09:08 AM

Rides with short, steep climbs are actually easier for me...the type of climbs that I'm riding above threshold for 5-20 minutes. I'm the type of rider with a good "VO2max" type power, with repeatability. The rides with big, long climbs are the ones that wear me down. There are several climbs that I ride semi-regularly, 3000-3500' of gain and take roughly an hour to climb. Doing 2 of those climbs in one ride feels considerably more difficult, to me, than doing a ride with 6000' of punchy climbing.

terrymorse 10-06-23 11:04 AM


Originally Posted by Sierra_rider (Post 23035411)
Rides with short, steep climbs are actually easier for me...the type of climbs that I'm riding above threshold for 5-20 minutes. I'm the type of rider with a good "VO2max" type power, with repeatability. The rides with big, long climbs are the ones that wear me down. There are several climbs that I ride semi-regularly, 3000-3500' of gain and take roughly an hour to climb. Doing 2 of those climbs in one ride feels considerably more difficult, to me, than doing a ride with 6000' of punchy climbing.

Interesting. Do you think your lactate threshold is relatively low compared to VO2max?

I'm kind of the opposite. Short, punchy climbs wear me out quickly (my legs, specifically), but I can tempo climb for several hours before fatigue sets in. At least I could in years past.

Sierra_rider 10-06-23 12:31 PM


Originally Posted by terrymorse (Post 23035536)
Interesting. Do you think your lactate threshold is relatively low compared to VO2max?

I'm kind of the opposite. Short, punchy climbs wear me out quickly (my legs, specifically), but I can tempo climb for several hours before fatigue sets in. At least I could in years past.

I've never actually done a VO2 max test, so I can't say for sure. However, I'm better at those higher intensity/above threshold efforts.

My 1 through 5 minute power numbers have always been very good compared to my FTP(at least since I've been using a power meter.) Oddly enough, I wouldn't call myself a sprinter either...as my 10 second power numbers are good, but not the "superlative" amount that my 1-5 are. I did go a long way in improving my endurance this year, FTP made big gains, as well as everything but my pure sprint power. I even set a PR for 1 minute power this year.


All times are GMT -6. The time now is 04:53 AM.


Copyright © 2026 MH Sub I, LLC dba Internet Brands. All rights reserved. Use of this site indicates your consent to the Terms of Use.