Now allows:
$ GoldenCheetah [[directory] athlete]
$ GoldenCheetah [--version|--help]
$ GoldenCheetah
Passing the athlete on its own is as before, but you can
now also pass the folder name in as well.
I've also added the option to get a help message if you
pass --version or --help.
Lastly, as before, with no command line paramaters you
open the last athlete worked on.
Since we now output the version and build info I have uplifted
the build and version numbers in GcUpgrade.h to reflect the fact
we are now developing v3.1.
When closing down we left the training database open
and this caused problems when looking to implement
a restart function.
The problems stemmed from the way the QSqlDatabase
code was implemented in TrainDB which was modelled on
code in DBAccess that was cleaned up subsequently.
TrainDB code now mirrors the approach taken in DBAccess
and relinquishes resources correctly. The TrainDB is now
closed as well as being opened in main.cpp at startup.
Also, removed reference to obsolete dbconn member in the
DBAccess class definition since it is no longer used.
Allow the user to select a directory to use for the
athlete libary. Leaving it blank will continue to use
the default location (dependent on platform).
If it is changed the user will be asked to confirm
and then GC shuts down.
Restart wouldn't work due to issues with the DBAccess
QSqlDatabase connection (which is really annoying). I
will look into this as a restart option would be much
cleaner.
Its only taken 4 years to implement this feature! (ouch).
Fixes#282.
.. accidentally left at 0s now corrected back
to truncate at tau for the 2 parameter model
and set to 25s for the 3 parameter mode where
it seems to breakdown.
Let the user define whether to use a 2 point or
3 point model (Morton et al).
In addition, let the user define the interval durations
to use; by default we set to 3 and 30 mins.
For estimating CP against good, recent data both of these
models are more than adequate for the purpose.
We'll just keep kicking the can down the road whilst we
can rely on published, verified science.
DJ Connel implemented a 3 point model, after Morton,
which was erroneously removed in a prior commit.
Our thanks to Andy Coggan for pointing this out in a
recent webinar. Nice to know he is following us closely.
.. don't refresh when not visible!
This is a side effect of the code updates added
to handle filtering in chart settings or the global
search/datafilter box.
.. another method for find intervals to find the ascents
in a ride. Uses the hysteresis as defined in options
which means a climb ends if there is a descent of that
or more (by default only 3m).
.. you can now choose to remove reference lines in the
allplot when you double click on the axis.
.. we might want to put the table and buttons for deleting
references into the chart settings too (?)
Too much going on and gets noisy, especially in stack mode.
Might extend this to the other plots, but need to live with
it for a while to see if the ticks were actually useful (!)
So you can unzoom in ride plot when you've zoomed in
to an interval -- avoiding having to show fullplot to
do the same thing manually.
There are probably other places to add functionality
for zooming out, will deal with those as they arise.
Added auto finding matches in Wprime, but there are
two areas to develop further;
1. Use the W'bal data to find matches instead of the
power above CP (which is really being used as a proxy
for the better approach).
2. Update the 'find intervals' dialog to allow you to
find matches and add them as normal intervals.
Pushing to repo as a version checkpoint, this function
will definitely need refining before 3.1 is released.
You can now plot NP, xPower and aPower on the
ride plot.
This has been done to provide transparency &
insight into the relationship between the derived
values and the recorded power values,
Peak aPower durations now computed and cached;
* updated RideFileCache to work with aPower
* CP curve now allows you to plot aPower
* LTM plot allows you to plot aPower peaks
* DataFilter allows 'best(apower, duration)' function
Added comment in ridefile.cpp to reference the book
and research paper that aPower is based upon:
// Calculate derived data series, including a new metric aPower
// aPower is based upon the models and research presented in
// "Altitude training and Athletic Performance" by Randall L. Wilber
// and Peronnet et al. (1991): Peronnet, F., G. Thibault, and D.L. Cousineau 1991.
// "A theoretical analisys of the effect of altitude on running
// performance." Journal of Applied Physiology 70:399-404
Added an average aPower metric.
I also and found and fixed a couple of bugs along the way;
* intervals create a ridefile and need to explicitly call
recalculateDerivedMetrics()
* the aPower calculation was using the calculated vo2max
percentage the wrong way around (!)
Introduce altitude adjusted power 'aPower'.
This is a new ride data series that takes into account
the effect of altitude on power output.
At present we are only adding this as a derived data series
with the intention of making it possible to plot it on
the ride chart.
We will also introduce alternate metrics for average power,
bikescore etc that are based upon the aPower value.