Skip to content

Compute Expected Shortfall and Value at Risk for Continuous Distributions

1packages depend
153.6Kdownloads / year
89.2%test coverage
13/13flavors OK

Overview

About

Compute expected shortfall (ES) and Value at Risk (VaR) from a quantile function, distribution function, random number generator, probability density function, or data. ES is also known as Conditional Value at Risk (CVaR). Virtually any continuous distribution can be specified. The functions are vectorized over the arguments. The computations are done directly from the definitions, see e.g. Acerbi and Tasche (2002) doi:10.1111/1468-0300.00091. Some support for GARCH models is provided, as well.

Changes in 0.6.1
  • fixed a test failing after a change in the arguments of RNGkind in R-devel =svn r90299=.

From NEWS.md in the release

Install

Health

CRAN checks
13OK
Slowest check: 2.0 min · r-oldrel-macos-x86_64
Status changes
  • OK13 OK2026-08-26
  • ERROR10 OK, 3 ERROR2026-07-27
  • OK13 OK2026-06-09
  • ERROR12 OK, 1 ERROR2026-06-08
  • OK14 OK2026-03-10
Advisories

none known

Documentation

In release 0.6.1
READMEYes · 379 wordsVignettesYes · 1 · dynamicNEWSYes · 100% structured · mentions 0.6.1Citation fileNoWebsiteYes · pkgdown
Help pages
6includes a package overview page
Examples that run
80%4 run in a plain check · 1 hold no code
Exported functions with examples
75%
Documented parameters
92%
Return-value docs
75%
Help pages citing references
17% with a bibliography file

Downloads

153.6K
CRAN downloads in the past year
Rank #1,138 · ~421/day · ~12.8K/mo
Daily download trend is not available in this view yet.
11.6K30 days
31.1K90 days
153.6K1 year
Compare downloads with other packages →
Also on1.9K r2u17 autocran1.1K conda_forge128 c2d4u

Repository

6Stars
3Forks
0Open issues
0Open PRs
0Releases
68Commits
2Commit identities
value-at-riskexpected-shortfallriskquantile-functionslocations-scale-transformationsquantile
68 commits · Last activity 2026-08-25 · 0% stars, 30d
Responsiveness
How these are sampled
PRs merged (all time)
not measured
Median days to close, 50 most recently updated closed issues
6
Median days to close, 50 most recently updated closed PRs
not measured

Stars over time

2024-08-02 · 62026-07-07 · 6
PracticesBeta

6 development-tooling and community-health practices detected across 3 families in the upstream repository

Checks run against github.com/geobosh/cvar on 2026-10-11.

Continuous integration (2)
GitHub ActionsR CMD check workflow

The R CMD check workflow runs on Linux, macOS and Windows, and on R-devel

Docs source (3)
pkgdown

GitHub Pages site last deployed 2022-11-09 · The repository has a site deploy workflow

pkgdown site last built 2022-11-09, before release 0.6.1 (2026-08-21)

Coverage (1)
Coverage reporting
How this is detected·Detection ruleset v3 (2026-09-26)

Dependencies

Declared dependencies
5 external dependencies (excludes base and recommended)

Installing cvar adds 3 packages (1 with compiled code, 1.6 MB of source tarballs). Heaviest: rbibutils 1.1 MB, Rdpack 370 KB, gbutils 164 KB.

Depends (0)
none
Imports (2)
LinkingTo (0)
none
Enhances (0)
none
Reverse dependencies
1direct
52indirect
Imports 1
Depends, Imports or LinkingTo, most downloaded first

People & History

People (1)
Author, Maintainer since 0.1-1 (2018)
Listed in earlier versions (1)
Boshnakov
no longer listed · 0.2-0 to 0.6.1
Releases (8)

Pick two releases to compare their code metrics.

  • 0.6.1Latest
    record
    2026-08-21 · current release · diff ↗
  • R
    R 4.6.0 released · 2026-04-24
  • 0.6
    record
    2025-12-17 · diff ↗
  • R
    R 4.5.0 released · 2025-04-11
  • R
    R 4.4.0 released · 2024-04-24
  • R
    R 4.3.0 released · 2023-04-21
  • 0.5
    record
    2022-11-03 · diff ↗
  • 0.4.1
    record
    2022-09-19 · diff ↗
  • R
    R 4.2.0 released · 2022-04-22
  • R
    R 4.1.0 released · 2021-05-18
  • R
    R 4.0.0 released · 2020-04-24
  • R
    R 3.6.0 released · 2019-04-26
  • 0.4-0
    record
    2019-03-15 · diff ↗
  • 0.3-0
    record
    2018-10-06 · diff ↗ ·
    added 2 exports
    GarchModel, sim_garch1c1
  • 0.2-0
    record
    2018-08-19 · diff ↗
  • R
    R 3.5.0 released · 2018-04-23
Show 2 earlier eventsHide 2 earlier events
  • 0.1-1
    record
    2018-04-09
  • R
    R 3.4.0 released · 2017-04-21

Package metadata

First published
2018-04-09
Total releases
8 / 8 yrs
License
GPL (>= 2) OSI
Download size
129 KB
Appears in task views

Cite

Cite this package

Run in R for the authors' preferred citation:

citation("cvar")
Boshnakov, G. N. (2026). cvar: Compute Expected Shortfall and Value at Risk for Continuous Distributions (Version 0.6.1) [Computer software]. https://doi.org/10.32614/CRAN.package.cvar

This package has no citation file, so citation() returns this entry built from DESCRIPTION.

Cite the R Observatory

For a number measured here: a download total, a coverage figure, an archival date.

APA

Balamuta, J. J. (2026). R Observatory: Metrics for cvar version 0.6.1 [Data set]. HJJB, LLC. Data release v2026-10-18. https://doi.org/10.5281/zenodo.21843040

From data release v2026-10-18, which the citation names so these numbers can be found later. More on citing and the projects behind them.

Report a problem with this page →

Privacy choices

These apply to this browser and are stored on this device only. Nothing about your choice is sent to us.

Read the privacy policy