Last active
December 26, 2015 22:39
-
-
Save Restuta/7224644 to your computer and use it in GitHub Desktop.
charts for flexicharts from http://www.cyclinganalytics.com/
This file contains 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
rides | |
.avg_power() | |
.filter(function(ride) { | |
return !ride.has.gps; | |
}) | |
.line({color: 'hsl(270, 70%, 70%)', name: 'Average PWR'}) | |
rides | |
.avg_heartrate() | |
.filter(function(ride) { | |
return !ride.has.gps; | |
}) | |
.line({color: 'hsl(170, 70%, 70%)', name: 'Average HR'}) | |
.on(-1) | |
rides | |
.avg_power() | |
.filter(function(ride) { | |
return ride.has.power && (ride.summary.avg_heartrate >= 140 && ride.summary.avg_heartrate <= 150); | |
}) | |
.line({color: 'hsl(270, 70%, 70%)', name: 'Average PWR'}) | |
rides | |
.avg_heartrate() | |
.filter(function(ride) { | |
return ride.has.power && (ride.summary.avg_heartrate >= 140 && ride.summary.avg_heartrate <= 150) ; | |
}) | |
.line({color: 'hsl(170, 70%, 70%)', name: 'Average HR'}) | |
.on(-1) | |
//will show avg pwc grouped by week, so I can see trends | |
rides.pwc150().group_by(week).aggregate(average).line() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment