Description Usage Arguments Value See Also Examples

View source: R/boptimal_cost.R

Define the optimal function to find the optimal test plans with minimum expected overall costs (for binomial RDT).

1 | ```
boptimal_cost(Cf, Cv, G, Cw, N, Rvec, cvec, pi, thres_CR)
``` |

`Cf` |
Fixed costs of RDT |

`Cv` |
Variable unit costs of RDT |

`G` |
Reliabilty growth cost |

`Cw` |
Average cost per warranty claim |

`N` |
Sales volume |

`Rvec` |
Vector of lower level reliability requirements |

`cvec` |
Vector of maximum allowable failures |

`pi` |
Failure probability |

`thres_CR` |
Threshold (acceptable level) of consumer's risk |

Vector of optimal test plan parameters, acceptance probabiltiy and cost

`boptimal_n`

for getting the optial test sample size;
`bdata_generator`

for generating optimal test plans dataset;

1 2 3 4 5 | ```
Rvec <- seq(0.8, 0.85, 0.01)
cvec <- seq(0, 2, 1)
pi <- pi_MCSim_beta(M = 5000, seed = 10, a = 1, b = 1)
boptimal_cost(Cf = 10, Cv = 10, G = 100, Cw = 10,
N = 100, Rvec = Rvec, cvec = cvec, pi = pi, thres_CR = 0.5);
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.