Version: | 0.0-2 |
Date: | 2024-01-19 |
Title: | Blood Pressure Device Accuracy Evaluation: Statistical Considerations |
Maintainer: | Victor Miranda <victor.miranda@aut.ac.nz> |
Depends: | R (≥ 4.2.0), methods, stats |
Description: | A comprehensive statistical analysis of the accuracy of blood pressure devices based on the method of AAMI/ANSI SP10 standards developed by the AAMI Sphygmomanometer Committee for indirect measurement of blood pressure, incorporated into IS0 81060-2. The 'bpAcc' package gives the exact probability 'of accepting a device D' derived from the join distribution of the sample standard deviation and a non-linear transformation of the sample mean for a specified sample size introduced by Chandel et al. (2023) and by the Association for the Advancement of Medical Instrumentation (2003, ISBN:1-57020-183-8). |
License: | GPL-2 |
NeedsCompilation: | yes |
BuildVignettes: | yes |
Packaged: | 2024-01-18 21:39:39 UTC; vico |
Author: | Victor Miranda [cre, aut, cph], Tanvi Chandel [aut], Andrew Lowe [aut], Tet Chuan Lee [aut], Auckland_University_of_Technology (AUT) [cph, fnd] |
Repository: | CRAN |
Date/Publication: | 2024-01-18 22:20:02 UTC |
Acceptance Region - ANSI/AAMI-SP10 standard.
Description
Acceptance Region for a given sample size to comply with ANSI/AAMI-SP10 standard.
Usage
AcceptR(n,distribution = "normal",criteria = "SP10:2006")
Arguments
n |
Sample size . |
distribution |
Underlying distribution the errors |
criteria |
SP10 criteria used. |
Details
Computes the revised probability of tolerable error i.e. the minimum probability of errors \delta
within tolerable error for a given sample size-n
. The tolerable error, according to the ANSI/AAMI-SP10, is an error between -10 mmHg to 10 mmHg on a single person, using average of that person's readings. The revised probability of tolerable error varies for different sample sizes. Thus to meet the SP10 criteria, an acceptance region based on the sample size is provided by the package.
\int_{-\infty}^{\delta} f_N(x;\mu_0,\sigma)-\int_{-\infty}^{-\delta} f_N(x;\mu_0,\sigma) \; dx = \hat{p}
Complete details in Chandel, et al. (2023).
The paper outlines he mathematical and
statistical aspects behind AcceptR
.
Value
It returns the acceptance region for a sample size i.e the upper limit of sd
for a sample mean for a given n
. This gives clinicians a flexible way to comprehend how the upper limit of the standard deviation -sd
fluctuates depending on the sample size.
Author(s)
Tanvi Chandel, Tet-Chuan Lee, Andrew Lowe, Victor Miranda.
References
Chandel, T. and Lee, TC. and Lowe, A. and Miranda, V. (2023) Blood Pressure Device Accuracy Evaluation: Statistical Considerations with an Implementarion in R, Statistics in Medicine (under review).
Examples
## SP10-Acceptance Region for a sample size (n) = 85
AcceptR(n=85,distribution = "normal",criteria = "SP10:2006")
## SP10-Acceptance Region for a sample size (n) = 50
AcceptR(n=50,distribution = "normal",criteria = "SP10:2006")
Probability of acceptance - ANSI/AAMI-SP10 standard.
Description
Probability of acceptance - ANSI/AAMI-SP10 standard.
Usage
PAccept(xbar,sd,N,distribution = "normal", criteria = "SP10:2006")
Arguments
xbar , sd |
mean and standar deviation of the average errors distribution (normal). |
N |
Sample size (number of participants). |
distribution |
Underlying distribution the errors |
criteria |
SP10 criteria used. |
Details
Computes the acceptance probability of a device D for
blood pressure measuring under the ANSI/AAMI-SP10 standards
for a size-n
sample of average errors from an asymptotically normal
distribution with mean xbar
and stadard deviation sd
.
1-\frac{1}{2}[1+erf(\frac{0.78-\hat{p}}{\sqrt(2)(\frac{\hat{p}(1-\hat{p})}{N})})]
The distribution is of the true probability of tolerable error p
where the
tolerable error according to the ANSI/AAMI-SP10, is an error between -10 mmHg
to 10 mmHg on a single person, using average of that person's readings. Using
the sampling distribution of sampling proportion, the probabilty of
p>=0.78
is evaluated, which is called as the probabilty of acceptance or
probability that for a given sample size n
, sample mean xbar
and
sample standard deviation sd
, the device is meeting the SP10 criteria.
Complete details in Chandel, et al. (2023).
The paper outlines the mathematical and
statistical aspects behind PAccept
. The threshold probability for acceptance according to ANSI/AAMI-SP10 is 95% i.e.,Prob(p>=0.78) >= 0.95
Value
It returns the probability of a device meeting the SP10 criteria
Author(s)
Tanvi Chandel, Tet-Chuan Lee, Andrew Lowe, Victor Miranda.
References
Chandel, T. and Lee, TC. and Lowe, A. and Miranda, V. (2023) Blood Pressure Device Accuracy Evaluation: Statistical Considerations with an Implementarion in R, Statistics in Medicine (under review).
Examples
## Probability of acceptance of a device for a sample size (N) = 30 with sample
## mean (xbar) = 5, standard deviation = 5.
PAccept(xbar=5,sd=5,N=30,distribution = "normal", criteria = "SP10:2006")
## Probability of acceptance of a device for a sample size (N) = 60 with sample
## mean (xbar) = 2, standard deviation = 7.
PAccept(xbar=2,sd=7,N=60,distribution = "normal", criteria = "SP10:2006")
Probability of device acceptance - AANSI/AAMI-SP10 standard.
Description
Probability of device acceptance - AANSI/AAMI-SP10 standard.
Usage
ProbAccept(n, mu, sd, ptolerror = 0.85,
distribution = "normal",
criteria = "SP10:2006",
simulate = FALSE, sim.count = 1e4,
noshow = FALSE)
Arguments
n |
Sample size (evaluated people, as defined by Chandel et al. (2022)). |
mu , sd |
mean and standar deviation of the average errors distribution (normal). |
ptolerror |
Probability of tolerable error. Default is 0.85 |
distribution |
Underlying distribution the errors |
criteria |
SP10 criteria used. |
simulate |
Logical. If |
sim.count |
Integer, positive. Number of samples taken from normal distribution to estimate the probability of accepting the device. |
noshow |
Logical. If |
Details
Computes the acceptance probability of a device D for
blood pressure measuring under the ANSI/AAMI-SP10 standards
for a size-n
sample of average errors from a normal
distribution with mean mu
and stadard deviation sd
.
The probability of tolerable error is set to 0.85, by default.
A tolerable error, according to the ANSI/AAMI-SP10,
is a an error of 10mmHg or
less on a single person, using the average of that person's readings.
Fuller details in Chandel, et al. (2022).
The paper outlines the mathematical and
statistical aspects behind ProbAccept
. Two random variables
are involved: the sample standard deviation and a transformation
of the sample mean, resulting in a double integral
over a two-dimensional region.
Value
It returns the probability of accepting the device (either simulated or exact).
Author(s)
Tanvi Chandel, Tet-Chuan Lee, Andrew Lowe, Victor Miranda.
References
Chandel, T. and Lee, TC. and Lowe, A. and Miranda, V. (2022) Blood Pressure Device Accuracy Evaluation: Statistical Considerations with an Implementarion in R, Statistical Methods in Medical Research (under review).
See Also
Examples
## Probability of accepting a device with bias (mu) = 5, and true standard
## deviation = 5.
ProbAccept(n = 85, mu = 5, sd = 5, ptolerror = 0.85)
## Probability of accepting a device with bias (mu) = 5, and true standard
## deviation = 7.
ProbAccept(n = 85, mu = 5, sd = 7, ptolerror = 0.85)
Probability of tolerable error - AAMI-SP10 standard.
Description
Probability of tolerable error - AAMI-SP10 standard.
Usage
ProbTolError(distribution = "normal", mu, std.dev, delta)
Arguments
distribution |
The errors distirbution. Default and only option is "normal". |
mu , std.dev |
Mean and standar deviation of the average errors distribution (normal). |
delta |
Maximum average error allowed for the device D. |
Details
Computes the probability of tolerable error for a device D for
blood pressure measuring under the ANSI/AAMI-SP10 standard
for a size-n
sample of average errors from a normal
distribution with mean mu
and stadard deviation sd
.
The maximum error accepted is 0.85,
A tolerable error, according to the ANSI/AAMI-SP10,
is a an error of 10mmHg or
less on a single person, using the average of that person's readings.
Currently, only normally distirbuted errors are handled. Further choices will be implemented over time.
Fuller details in Chandel, et al. (2022).
Value
It returns the probability of tolerable error based on a normal distribution.
Author(s)
Tanvi Chandel, Tet-Chuan Lee, Andrew Lowe, Victor Miranda.
References
Chandel, T. and Lee, TC. and Lowe, A. and Miranda, V. (2022) Blood Pressure Device Accuracy Evaluation: Statistical Considerations with an Implementarion in R, Statistical Methods in Medical Research (under review).
See Also
Examples
## Probability of tolerable error, mu = 4, sd = 5, delta = 10 (ANSI/AAMI-SP10)
ProbTolError(mu = 4, std.dev = 5, delta = 10)
Supplementary fuctions of the package bpAcc.
Description
Supplementary function required to compute the acceptance probability of a device for BP measurement.
Usage
fsup1(mu, sd.aami, ptolerror)
fsup2(mu.aami, sdev, ptolerror)
toint(xbar, mean, sd, n)
Arguments
mu |
True mean error (bias). This is 'mu' of the errors distribution (normal). |
sd.aami |
Standard deviation of a normal distribution meeting the ANSI/AAMI-SP10 standards. |
ptolerror |
Probability of tolerable error. Default is 0.85. |
mu.aami |
Mean of a normal distribution meeting the ANSI/AAMI-SP10 standards. |
sdev |
True standard deviation of the errors (normal distribution). |
xbar , mean , sd , n |
Auxiliary arguments. |
Details
Supplementary functions to compute
the probability of accepting the device D.
The errors (average of the differences from
three device measurements and the three corresponding reference
readings) are by default normally distributed with mean
mean
and sd
. Function fsup1
is called
by root
, fsup2
is
needed by rootinv
, and
toint
is required by psigmaami
.
See psigmaami
for further
details on ptolerror
.
Value
No value returned.
These are funtcion internally called by
ProbAccept
.
Author(s)
Tanvi Chandel, Tet-Chuan Lee, Andrew Lowe, Victor Miranda.
References
Chandel, T. and Lee, TC. and Lowe, A. and Miranda, V. (2022) Blood Pressure Device Accuracy Evaluation: Statistical Considerations with an Implementarion in R, Statistical Methods in Medical Research (under review).
See Also
Examples
#### 'sd' that meets the AAMI-sp10 standars
root(mu = 5, ptolerror = 0.9)
# root(mu = 11, ptolerror = 0.85) # Error
#### 'mu' that meets the AAMI-sp10 standars
rootinv(sdev = 3, ptolerror = 0.9)
# rootinv(sdev = 2, ptolerror = 0.85) # Error
Methods functions in bpAcc
Description
The function ProbAccept
returns an object of (S4) class 'ProbAcceptance
', a list
with elements required by methods defined
for ProbAcceptance
objects. See below.
Methods
Methods for objects of class 'ProbAcceptance
'.
show
-
To display the probability of tolerable error in a friendly version.
plot
-
To plot the estimated probabiliy of tolerable error based on simulated data, as described in
ProbAccept
Examples
# Creates an object of class 'ProbAcceptance' fit1 <- ProbAccept(n = 85, mu = 5, sd = 5, ptolerror = 0.85)
# Methods 'show' and 'plot' # plot(fit1) # fit1
Not-documented functions and classes in bpAcc.
Description
Those functions not documented yet in bpAcc are aliased to this file.
Details
These functions are still under review or being tested, and will be documented over time.
Value
Overall, these functions returns objects required by functions from bpAcc.
Further details will be given shortly.
Author(s)
T. Chandel, V. Miranda, A. Lowe, T. Lee
Distribution function of the sigma-aami transformation (not vectorized).
Description
Distribution function of the sigma-aami transformation (not vectorized).
Usage
psigmaami(sigmaami, mu, std.dev, n, ptolerror = 0.85, lower.tail = TRUE)
Arguments
sigmaami |
A single, positive, quantile. See below for further details. |
mu , std.dev |
mean and standar deviation of the average errors distribution (normal). |
n |
sample size |
ptolerror |
Probability of tolerable error, Default is 0.85 |
lower.tail |
logical; it TRUE (default), probabilities are
|
Details
This is the distribution function of the sigmaami
transformation.
A size-n sample of blood pressure average errors (average of
the difference between three device measurements
and the three corresponding reference readings)
is drawn from a normal distribution
with mean mu
and standard deviation std.dev
.
The r.v. sigmaami
results from transforming xbar
, the
sample mean, assuming the proportion of drawn errors lie in
(-delta
, delta
)
with probability ptolerror
, that is
sigmaami
=sigmaami(xbar)
.
Value
psigmaami
gives the distribution function.
Author(s)
Tanvi Chandel, Tet-Chuan Lee, Andrew Lowe, Victor Miranda.
References
Chandel, T. and Lee, TC. and Lowe, A. and Miranda, V. (2022) Blood Pressure Device Accuracy Evaluation: Statistical Considerations with an Implementarion in R, Statistical Methods in Medical Research (under review).
See Also
Examples
## Sample of n = 85 average errors from a normal distribution with mean 3 and st.dev = 2.
psigmaami(sigmaami = 4, mu = 3, std.dev = 2, n = 85)