Title: | Clinical and Laboratory Standards Institute (CLSI) EP15-A3 Calculations |
---|---|
Description: | Calculations of "EP15-A3 document. A manual for user verification of precision and estimation of bias" CLSI (2014, ISBN:1-56238-966-1). |
Authors: | Claucio Antonio Rank Filho [aut, cre] |
Maintainer: | Claucio Antonio Rank Filho <[email protected]> |
License: | MIT + file LICENSE |
Version: | 0.1.0 |
Built: | 2024-12-04 07:02:37 UTC |
Source: | CRAN |
Calculate bias validation interval
bias_validation_interval(TV, m, se_c)
bias_validation_interval(TV, m, se_c)
TV |
True value |
m |
factor |
se_c |
SE Combined |
named list with the interval
Calculate ANOVA Results and Imprecision Estimates
calculate_aov_infos(ep_15_table)
calculate_aov_infos(ep_15_table)
ep_15_table |
table generated from create_table_ep_15() |
Named list with ANOVA Results and Imprecision Estimates
calculate_aov_infos(create_table_ep_15(CLSIEP15::ferritin_long, data_type = 'long'))
calculate_aov_infos(create_table_ep_15(CLSIEP15::ferritin_long, data_type = 'long'))
Calculate bias interval from TV
calculate_bias_interval( scenario, nrun, nrep, SWL, SR, nsamples, expected_mean, user_mean, ... )
calculate_bias_interval( scenario, nrun, nrep, SWL, SR, nsamples, expected_mean, user_mean, ... )
scenario |
Choosed scenario from section 3.3 of EP15-A3 |
nrun |
Number of runs |
nrep |
number of repetitions per run (n0) |
SWL |
S within laboratory (obtained from anova) |
SR |
S repetability (obtained from anova) |
nsamples |
total number of samples tested usual 1 |
expected_mean |
Expected mean or TV |
user_mean |
Mean of all samples (obtained from anova) |
... |
additional parameters necessary for processing the choosed scenario |
a named list with the defined mean, the interval significance (user mean should be in for approval), and total bias (user mean - TV)
calculate_bias_interval(scenario = 'E', nrun = 7, nrep = 5, SWL = .042, SR = .032, nsamples = 2, expected_mean = 1, user_mean = .94 )
calculate_bias_interval(scenario = 'E', nrun = 7, nrep = 5, SWL = .042, SR = .032, nsamples = 2, expected_mean = 1, user_mean = .94 )
Calculate degrees of freedom of SE C (SE combined) given a selected scenario and additional parameters necessary for the scenario
calculate_df_combined(scenario, ...)
calculate_df_combined(scenario, ...)
scenario |
Scenario (A, B, C, D, E) |
... |
additional parameters necessary for the scenario |
DF
Calculate degres of freedom within-lab as specified in appendix B
calculate_dfWL(cvr_manufacture, cvwl_manufacture, k, n0, N)
calculate_dfWL(cvr_manufacture, cvwl_manufacture, k, n0, N)
cvr_manufacture |
CV repeatability informed by the manufacturer |
cvwl_manufacture |
CV within-lab informed by the manufacturer |
k |
the number of runs |
n0 |
the “average” number of results per run |
N |
the total number of replicates |
dfwl
Calculate the UVL factor
calculate_F_uvl(nsamp = 1, df, alpha = 0.05)
calculate_F_uvl(nsamp = 1, df, alpha = 0.05)
nsamp |
n samples in the study |
df |
degres of freedom |
alpha |
confidence level |
Uvl factor
Calculate M
calculate_m(df, conf.level = 95, nsamples = 1)
calculate_m(df, conf.level = 95, nsamples = 1)
df |
degrees of freedom |
conf.level |
confidence interval |
nsamples |
number of samples |
m factor
Calculate n0
calculate_n0(long_result_table)
calculate_n0(long_result_table)
long_result_table |
table generated by create_table_ep_15 function |
The n0 number which refers to Number of Results per Run
Calculate SE combined based on SE X and SE RM
calculate_se_c(se_x, se_rm)
calculate_se_c(se_x, se_rm)
se_x |
SE X |
se_rm |
SE RM |
SE C
Calculate SE RM given a scenario and a list of additional args that can change based on the selected scenario or sub scenario
calculate_se_rm(scenario, additional_args)
calculate_se_rm(scenario, additional_args)
scenario |
scenario (A, B, C, D, E) |
additional_args |
additional arguments list |
SE RM
Calculate SE RM for scenario A when f the manufacturer supplies lower and upper limits and coverage confidence interval (95 or 99...)
calculate_se_rm_a_lowerupper(upper, lower, coverage)
calculate_se_rm_a_lowerupper(upper, lower, coverage)
upper |
upper limit |
lower |
lower limit |
coverage |
coverage |
SE RM
Calculate SE RM for scenario A when “standard error” or “standard uncertainty” (abbreviated by lowercase “u”) or “combined standard uncertainty” (often denoted by “uC ”)
calculate_se_rm_a_u(u)
calculate_se_rm_a_u(u)
u |
“standard error” or “standard uncertainty” (abbreviated by lowercase “u”) or “combined standard uncertainty” (often denoted by “uC ”) |
SE RM
Calculate SE RM for scenario A when f the manufacturer supplies an “expanded uncertainty” (abbreviated by uppercase “U”) for the TV and coverage e.g. 95 or 99,
calculate_se_rm_a_Ucoverage(U, coverage)
calculate_se_rm_a_Ucoverage(U, coverage)
U |
expanded uncertainty |
coverage |
coverage |
SE RM
Calculate SE RM for scenario A when f the manufacturer supplies an “expanded uncertainty” (abbreviated by uppercase “U”) for the TV and the “coverage factor” (abbreviated by “k”)
calculate_se_rm_a_Uk(U, k)
calculate_se_rm_a_Uk(U, k)
U |
expanded uncertainty |
k |
coverage factor |
SE RM
Calculate SE RM for scenario B or C If the reference material has a TV determined by PT or peer group results
calculate_se_rm_scenario_b_c(sd_rm, nlab)
calculate_se_rm_scenario_b_c(sd_rm, nlab)
sd_rm |
SD RM |
nlab |
number of lab or peer group results |
SE RM
Calculate SE RM for scenario D or E If the TV represents a conventional quantity value or When working with a commercial QC material supplied with a TV for which the standard error cannot be estimated
calculate_se_rm_scenario_d_e()
calculate_se_rm_scenario_d_e()
SE RM
Calculate SE x
calculate_se_x(nrun, nrep, SWL, SR)
calculate_se_x(nrun, nrep, SWL, SR)
nrun |
Run number |
nrep |
Number of repetitions per run n0 |
SWL |
SWL from aov table |
SR |
SR from aov table |
SE X
Generic function for calculating UVL the return is a named list and cv_uvl_r and cv_uvl_wl depends on what is the input (S or CV) if the input is SR and SWL the returns is S
calculate_uvl_info(aov_return, nsamp = 1, cvr_or_sr, cvwl_or_swl)
calculate_uvl_info(aov_return, nsamp = 1, cvr_or_sr, cvwl_or_swl)
aov_return |
Return of calculate_aov_info() |
nsamp |
number of samples in the experiment |
cvr_or_sr |
Desirable CV or S repetability |
cvwl_or_swl |
Desirable CV or S within-lab |
Named list with UVL params
data <- create_table_ep_15(ferritin_wider) aov_t <- calculate_aov_infos(data) calculate_uvl_info(aov_t, nsamp = 5, cvr_or_sr = .43, cvwl_or_swl = .7)
data <- create_table_ep_15(ferritin_wider) aov_t <- calculate_aov_infos(data) calculate_uvl_info(aov_t, nsamp = 5, cvr_or_sr = .43, cvwl_or_swl = .7)
Create table for precision calculations
create_table_ep_15(data, data_type = "wider")
create_table_ep_15(data, data_type = "wider")
data |
a long or a wider data.frame with the same structure of CLSIEP15::ferritin_long or CLSIEP15::ferritin_wider |
data_type |
c('wider', 'long') |
a data.frame with renamed columns and structure adjustments
data <- create_table_ep_15(ferritin_long, data_type = "longer")
data <- create_table_ep_15(ferritin_long, data_type = "longer")
Reference of degrees of freedon based on tau given in the CLSI Manual
dfc_references
dfc_references
'dfc_references' A data frame with 390 rows and 4 columns:
tau
degrees of freedon
number of labs or peers
number of runs
...
CLSI EP15-A3
Ferrtin data used in CLSI document examples in wide format
ferritin_long
ferritin_long
'ferritin_long' A data frame with 25 rows and 3 columns:
Repetition of sample
Run of the Runs obtained from 5 distinct days
result of the observation
...
CLSI EP15-A3
Ferrtin data used in CLSI document examples in wide format
ferritin_wider
ferritin_wider
'ferritin_wider' A data frame with 5 rows and 6 columns:
Repetition of sample
Runs from 5 distinct days
...
CLSI EP15-A3