Skip to main content

Calculation of trending concordance between two measures using the Error Field method

Project description

ErrorFieldConcordance

Thie package provides calculation (and optionally graphing) of trending/concordance between two measures using the Error Field Trending method.

Function Call

After importing the package, the method can be called as follows:

Concordance = ErrorFieldConcordance(X,Y,IDS=[], plot_TF=False,graph_label='',X_name='ΔX',Y_name='ΔY',min_plot_range=3,decolor_threshold=2)

Function Parameters:

  • The X and Y parameters are lists or arrays of equal size corresponding to paired measures to be compared. These should be the observations themselves (not the changes observed between observations).
  • IDS is a list of the same length as X & Y containing subject identifiers for individual subjects in the lists. If all of the observations are from the same subject this parameter can be empty.
  • plot_TF is a boolean that controls whether or not a figure is created.
  • graph_label is an optional string parameter to be placed in the graph title.
  • XMeasName and YMeasName are used to customize the X and Y graph labels if desired
  • MinPlotRange can be used to extend the plot range if desired. Normally the plot will include ± the largest absolute change observed, but if this range is too small the MinPlotRange parameter can be used to fix a minimum axis range.
  • decolor_threshold sets the radius for the desaturation circle at the center of the graph. This is a graphical/appearance modifier only, it has no effect on the calculation of the Error Field Trending value, but is useful to visually represent the central region where points are weighted the least in the final calculation.

###Notes The observations passed in X & Y (and the corresponding subject identifiers in IDs) should be grouped by subject and ordered temporally. The function will then calculate the changes in successive observations within subjects. If X, Y, and IDS are not grouped by subject and ordered by time results will be invalid.

Time differences in the observations should be based on the aims of the project; the function itself is agnostic to the specifics. Ideally the time differences are all the same, otherwise interpretation of the graph and results may be biased.

Output

The returned value is a tuple of (error field trending %, standard deviation %).

The error field trending value is a number in the range of [-100,100]:

  • Values > 60% indicate strong concordance.
  • Values between +20% and +60% indicate concordance.
  • Values between -20% and +20% indicate relative independence, or low overall change in the sample.
  • Values between -60% and -20% indicate discordance.
  • Values less than -60% indicate strong discordance.

Graphing

Example Error Field Concordance graph showing plotting of random data

The figure above shows an Error Field Concordance plot for two 1,000 sample arrays of noise (i.e. independent samples). The data demonstrates the fields in the plot, with blue zones indicating concordance (the measures move in the same direction and magnitude), red zones indicating discordance (the measures move in opposite directions), and yellow zones indicating relative independence of movement.

Citing

Please cite this package using the following: PubMed Reference & Citation TBD

Contributors

Thanks go out to Bernd Saugel, Sean Coeckelenbergh, Ishita Srivastava, and Brandon Woo for their collective contributions to this project.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

errorfieldconcordance-1.0.tar.gz (5.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ErrorFieldConcordance-1.0-py3-none-any.whl (6.3 kB view details)

Uploaded Python 3

File details

Details for the file errorfieldconcordance-1.0.tar.gz.

File metadata

  • Download URL: errorfieldconcordance-1.0.tar.gz
  • Upload date:
  • Size: 5.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.6

File hashes

Hashes for errorfieldconcordance-1.0.tar.gz
Algorithm Hash digest
SHA256 86b1ec59585120cc34f2ed2bf07d55b2d9ba07918ed36ebee9e1be6dcbe0e73f
MD5 cc1ff30138ba4fd681683247360fdee8
BLAKE2b-256 fc6d7ec2b4d1eb7698e661786d0029519de786ba3a67b258733b4782c1fa4e0d

See more details on using hashes here.

File details

Details for the file ErrorFieldConcordance-1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for ErrorFieldConcordance-1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3f39250df258cd7b9f8ffe3ff78671d124773e9e00b215c3daa9fe3290d487ed
MD5 7a13f0d0638d606b704e78af3324fa18
BLAKE2b-256 0cad723ef110caf0ddb341b7fc495163b72e876c5c69a549601f98b16cc4f9a5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page