Commit Graph

18 Commits

Author SHA1 Message Date
Alejandro Martinez
b984c340ba Refactor Measures
Part 5 of #2588
- BodyMeasures code in Athlete was moved to BodyMeasures class in Core
- HrvMeasures code in Athlete was moved to HrvMeasures class in Core
- Both implement the Abstract Base Class MeasuresGroup which provides uniform
  access to measures
- Class Measures consolidate access to Body/Hrv Measures
- Body/Hrv measures file is accessed for only one place
- Names/Symbols for Body/Hrv measures are defined only once
2017-11-19 00:14:26 -03:00
Alejandro Martinez
c1de1def02 HRV Measures - Part 3
Added HRV Measure fingerprint to RideItem fingerprint
to detect changes in HRV Measures potentially affecting
ride metrics.
2017-08-02 18:19:14 -03:00
Alejandro Martinez
2888b27e16 Adds HRV Measures - Part 1
Implements #2568 part 1, 2, 3, and 4
2017-07-26 17:17:21 -03:00
Joern
319c1f6702 Fix Terminology
... "measurements" (noun) not "measures" (verb) - thanks Mark
2017-04-22 19:44:45 +02:00
Keith Reynolds
5dc6e8eb1a Use defines for units
Fix precision loss issues
Remove unused variables
2017-03-31 10:09:35 -06:00
Joern
cb9b38dcc0 BodyMeasures
... add "source" and "originalSource"
... add "time" display for bodyMeasures read from cloud services
... store in /config not in /activities
... code clean-up (warnings, enum instead preprocessor constants)
2017-03-26 12:42:06 +02:00
Joern
c6c2121784 Introduce BodyMeasures as generalization of current Withings Data
... body measures are weight/height data as provided by multiple fitness platform (one of the being the already support Withings platform)
... all access to Weight from external platforms is done through the body measures model - not direct use of Withings any more
... not all platform deliver all measures - but (hopefully) all are providing "weight in kg" as a minimum data

General Download Dialog for Body Measures
... allowing to select the source and the daterange for which data is downloaded (e.g. only the new data since last available measure)
... Support existing Withings Download
... Support new Today's Plan as data source (which is able to receive measures from other sits - e.g. Garmin Connect)
... Support CSV files as data source

Store Body Measures Data in one fix file under /activities (not in /cache like Withings) (so that e.g. backup works like before).

What's open:

... CSV File Import (Info Message on missing feature)
... Test of "old" Withings Download API (since I can't do this)
2017-03-18 13:42:36 +01:00
Mark Liversedge
9d0b0b9b27 HRV Support Add stdmean() and stdvariance() to RideMetric
.. Leif Warland is developing the HRV metric support
   and some of these are std deviations. When you
   aggregate std deviations the mean and variances
   are needed.

.. RideMetric::stdmean() and ::stdvariance() return
   a value that is stored in the RideDB if it is
   non-zero.

.. RideItem::getStdMeanForSymbol()
   RideItem::getStdVarianceForSymbol

   return the stored value for use when aggregating in
   the same way that RideItem::getCountForSymbol() does.
2017-02-22 09:45:48 +00:00
Mark Liversedge
a6caf5f07a RideItem::getCountForSymbol return 1 not zero
.. a count of zero makes no sense, so it returns 1
   whenever the value is unset. This fixes averaging
   for metrics that don't bother to set count.
2017-02-21 13:33:29 +00:00
Mark Liversedge
a3be6bac46 LTMPlot aggregate metrics using count
.. don't fallback on workout_time, let the metrics supply
   the value to use.

Fixes #2353
2017-02-20 18:31:34 +00:00
Mark Liversedge
d4a1cbc250 RideCache stores count for each metric
.. the RideMetric::count() value is written to the ride
   cache (rideDB.json) if it is non-zero.

.. it is not used in the aggregation logic yet, but the
   rideDB version number has been incremented to force
   a rebuild on first run.
2017-02-20 17:50:46 +00:00
grauser
ffff355416 DataFilter : Match exact name for XDATA series 2016-11-21 21:14:22 +01:00
Mark Liversedge
a38696e25d Data Processor 'On Save' and Snippets
.. a data processor can now be configured to run on save

.. in addition, the data processor is now passed the operation
   that is triggering it: "Manual", "ADD", "UPDATE", "DELETE",
   "IMPORT".

.. a new data processor has been added to write a JSON file to
   the snippet directory (added to the athlete structure).

.. this is so we can output a snippet every time an activity is
   added, updated or deleted (i.e. runs "on save").

.. these JSON snippets can be used to update external datastores
   where coaches use other analytic software but don't want to
   manually sync GC changes with there external stores.
2016-11-12 22:36:44 +00:00
Mark Liversedge
635f27ccbd XDATA(name, series, ...) accepts wildcards
.. you can now use the XDATA function to return XDATA field
   values using a wildcard.

.. this is likely to be most useful for ignoring the xdata
   name when searching for a specific data series.

.. e.g. XDATA("*", "YAW", repeat) will get the YAW data series
   regardless of the name of the xdata name that the user
   chooses.
2016-09-08 20:25:19 +01:00
Mark Liversedge
ac37f48033 XDATA in DataFilter 1 of 3
.. Filter rides for presence of XDATA by name using the syntax:
   XDATA("XDATANAME", "SERIESNAME", sparse|repeat|interpolate|resample)

.. this is the first of 2 commits, in this one we have added XDATA to
   the rideitem and rideDB.json so we can check if XDATA is present
   without opening the ridefile

.. this allows us to return true or false for an XDATA(..) call when
   working across rideitems (not data points) in DataFilter evaluate,
   note that the join control (sparse,repeat etc) is ignored when you
   are filtering ride items

.. in the next commit we will add the ability to get at the xdata
   values when iterating in user data or user metrics

.. there are likely to be further refinements for the outer join
   required to support interpolation and resampling in a third commit.
2016-07-16 11:46:35 +01:00
Alejandro Martinez
bab562fb46 Deprecated BestIntervalDialog
Added Specification parameter to AddIntervalDialog::findPeaks
So it can be used as a more general replacement for
BestIntervalDialog::findBests and findBestsKPH
2016-07-12 11:23:47 -03:00
Alejandro Martinez
6937df7786 Add support for running HR zones part 3
Changed ride cache and charts to use zones according to sport(s)
2016-05-09 15:21:47 -03:00
Mark Liversedge
4b5201c4c5 Restructure source directory
Introducing a directory structure to make it a bit less
daunting for new developers and perhaps even old hands.

The main folders all start with an upper character, so src
files are now located in;

* Core - Core data structures
* Gui - Main GUI elements
* Metrics - Models and Metrics
* FileIO - Device and File I/O
* Charts - All the chart types
* Cloud - Working with Web Resources
* Train - Anything Train View specific
* ANT - Our ANT+ Stack
* Resources - Images, Translations, Web etc

Apologies to anyone who needs to merge across this update.
2016-02-25 14:51:53 +00:00