diagstats {diagmeta} | R Documentation |

## Calculate statistical measures of test performance for objects of
class `diagmeta`

### Description

The user can provide cutoffs, sensitivities, and / or specificities to calculate the respective quantities (with confidence intervals). Furthermore, positive predictive values (PPV), negative predictive values (NPV), and probabilities of disease (PD) are calculated if the prevalence is provided.

### Usage

```
diagstats(x, cutoff = x$optcut, sens, spec, prevalence, level = 0.95)
```

### Arguments

`x` |
An object of class |

`cutoff` |
A numeric or vector with cutoff value(s) |

`sens` |
A numeric or vector with sensitivity value(s) |

`spec` |
A numeric or vector with specificity value(s) |

`prevalence` |
A numeric or vector with the prevalence(s) |

`level` |
The level used to calculate confidence intervals |

### Value

A data frame of class "diagstats" with the following variables:

`cutoff` |
Cutoffs provided in argument "cutoff" and / or model-based cutoff values for given sensitivities / specificities. |

`Sens` |
Sensitivities provided in argument "sens" and / or model-based estimates of the sensitivity for given cutoffs / specificities |

`seSens` |
Standard error of sensitivity |

`lower.Sens` , `upper.Sens` |
Lower and upper confidence limits of the sensitivity |

`Spec` |
Specificities provided in argument "spec" and / or model-based estimates of the specificity for given cutoffs / sensitivities |

`seSpec` |
Standard error of specificity |

`lower.Spec` , `upper.Spec` |
Lower and upper confidence limits of the specificity |

`prevalence` |
As defined above. |

`PPV` |
Positive predictive value (based on the cutoff) |

`NPV` |
Negative predictive value (based on the cutoff) |

`PD` |
Probability of disease if the given cutoff value was observed as the measurement for an individual |

`dens.nondiseased` |
Value of the model-based density function at the cutoff(s) for non-diseased individuals |

`dens.diseased` |
Value of the model-based density function at the cutoff(s) for diseased individuals |

### Author(s)

Gerta RÃ¼cker gerta.ruecker@uniklinik-freiburg.de, Srinath Kolampally kolampal@imbi.uni-freiburg.de, Guido Schwarzer guido.schwarzer@uniklinik-freiburg.de

### See Also

### Examples

```
# FENO dataset
#
data(Schneider2017)
diag1 <- diagmeta(tpos, fpos, tneg, fneg, cutpoint,
studlab = paste(author, year, group),
data = Schneider2017,
log.cutoff = TRUE)
# Results at the optimal cutoff
#
diagstats(diag1)
# Results for cutoffs 25 and 50 (and a prevalence of 10%)
#
diagstats(diag1, c(25, 50), prevalence = 0.10)
# Results for sensitivity and specificity of 0.95
#
diagstats(diag1, sens = 0.95, spec = 0.95)
```

*diagmeta*version 0.5-1 Index]