Title: | Data Sets for Quantitative Risk Management Practice |
---|---|
Description: | Various data sets (stocks, stock indices, constituent data, FX, zero-coupon bond yield curves, volatility, commodities) for Quantitative Risk Management practice. |
Authors: | Marius Hofert [aut, cre], Kurt Hornik [aut], Alexander J. McNeil [aut] |
Maintainer: | Marius Hofert <[email protected]> |
License: | GPL-2 | GPL-3 |
Version: | 2024-03-04-2 |
Built: | 2025-01-24 03:41:21 UTC |
Source: | https://github.com/cran/qrmdata |
Data sets containing commodities.
data("OIL_Brent") data("GOLD")
data("OIL_Brent") data("GOLD")
xts
objects containing the Brent Crude price in USD per
barrel (for OIL_Brent
) and the World Gold Council gold price in USD
per troy ounce (for GOLD
).
Marius Hofert
The data was obtained from Federal Reserve Economic Data (FRED) via
Quandl on 2016-01-03 with the function
get_data()
from qrmtools.
data("OIL_Brent") data("GOLD")
data("OIL_Brent") data("GOLD")
Bitcoin, Ethereum, Litecoin and Ripple prices in USD (from their first available date onwards).
data("crypto")
data("crypto")
xts
object containing cryptocurrency prices in USD
of Bitcoin (ticker symbol “BTC-USD”), Ethereum (ticker symbol
“ETH-USD”), Litecoin (ticker symbol “LTC-USD”) and Ripple (ticker
symbol “XRP-USD”) from their first available date onwards.
Marius Hofert
The data was obtained from Yahoo Finance on 2018-05-29
via the function get_data()
from qrmtools.
data("crypto") str(crypto) library(xts) plot.zoo(crypto, main = "Cryptocurrencies in USD", xlab = "Time")
data("crypto") str(crypto) library(xts) plot.zoo(crypto, main = "Cryptocurrencies in USD", xlab = "Time")
A three-dimensional array containing the default data for A-, BBB-, BB-, B- and C-rated companies for the years from 1981 to 2000.
data("SP_defaults")
data("SP_defaults")
xts
objects containing foreign exchange rates of
Canadian Dollar (CAD_*
), US Dollar (USD_*
),
British Pound (GBP_*
), Euro (EUR_*
), Swiss Francs
(CHF_*
), Japanese Yen (JPY_*
), Chinese Yuan (CNY_*
)
with respect to USD (*_USD
) and GBP (*_GBP
) from
2000-01-01 to 2015-12-31.
Marius Hofert
Standard & Poor's Credit Monitor
data("SP_defaults")
data("SP_defaults")
Foreign exchange rate data with respect to USD and GBP.
data("CAD_USD") data("GBP_USD") data("EUR_USD") data("CHF_USD") data("JPY_USD") data("CNY_USD") data("CAD_GBP") data("USD_GBP") data("EUR_GBP") data("CHF_GBP") data("JPY_GBP") data("CNY_GBP")
data("CAD_USD") data("GBP_USD") data("EUR_USD") data("CHF_USD") data("JPY_USD") data("CNY_USD") data("CAD_GBP") data("USD_GBP") data("EUR_GBP") data("CHF_GBP") data("JPY_GBP") data("CNY_GBP")
xts
objects containing foreign exchange rates of
Canadian Dollar (CAD_*
), US Dollar (USD_*
),
British Pound (GBP_*
), Euro (EUR_*
), Swiss Francs
(CHF_*
), Japanese Yen (JPY_*
), Chinese Yuan (CNY_*
)
with respect to USD (*_USD
) and GBP (*_GBP
) from
2000-01-01 to 2015-12-31.
Interpretation: As an example, EUR_USD
contains the EUR/USD
exchange rate, so a value in
EUR_USD
indicates that 1 EUR is worth USD at that point in time.
Marius Hofert
The data was obtained from OANDA (https://www.oanda.com/) on
2016-01-03 via the
function get_data()
from qrmtools.
data("CAD_USD") data("GBP_USD") data("EUR_USD") data("CHF_USD") data("JPY_USD") data("CNY_USD") data("CAD_GBP") data("USD_GBP") data("EUR_GBP") data("CHF_GBP") data("JPY_GBP") data("CNY_GBP")
data("CAD_USD") data("GBP_USD") data("EUR_USD") data("CHF_USD") data("JPY_USD") data("CNY_USD") data("CAD_GBP") data("USD_GBP") data("EUR_GBP") data("CHF_GBP") data("JPY_GBP") data("CNY_GBP")
Zero-coupon bond yield curves in CAD and USD.
data("ZCB_CAD") data("ZCB_USD")
data("ZCB_CAD") data("ZCB_USD")
ZCB_CAD
:xts
object containing, in each row, zero-coupon bond yield curves
in percent for 120 times to maturity (ranging from 0.25 to 30 years); only
trading days from 1991-01-02 to 2015-08-31 with available values
for all maturities are included.
ZCB_USD
:xts
object containing, in each row, zero-coupon bond yield curves
in percent for 30 times to maturity (ranging from 1 to 30 years); only
trading days from 1985-11-25 to 2015-12-29 with available values
for all maturities are included.
Marius Hofert
ZCB_CAD
was created from data obtained from
https://www.bankofcanada.ca/rates/interest-rates/bond-yield-curves/
multiplied by 100. ZCB_USD
was obtained from
https://data.nasdaq.com/data/FED/SVENY-us-treasury-zerocoupon-yield-curve/
(active in 2016) via Quandl. Both data sets were drawn on 2016-01-03
(ZCB_USD
via the function get_data()
from qrmtools).
data("ZCB_CAD") data("ZCB_USD") mat <- as.matrix(ZCB_USD['2015-01-01/2015-12-31',]) df <- data.frame(Day = rep(1:nrow(mat), each = ncol(mat)), Maturity = rep(1:ncol(mat), nrow(mat)), Value = as.vector(t(mat))) lattice::wireframe(Value ~ Day * Maturity, data = df, alpha.regions = 0.5, scales = list(arrows = FALSE, col = "black"), par.settings = list(axis.line = list(col = "transparent")))
data("ZCB_CAD") data("ZCB_USD") mat <- as.matrix(ZCB_USD['2015-01-01/2015-12-31',]) df <- data.frame(Day = rep(1:nrow(mat), each = ncol(mat)), Maturity = rep(1:ncol(mat), nrow(mat)), Value = as.vector(t(mat))) lattice::wireframe(Value ~ Day * Maturity, data = df, alpha.regions = 0.5, scales = list(arrows = FALSE, col = "black"), par.settings = list(axis.line = list(col = "transparent")))
Danish fire insurance claims in 1M DKK in Denmark from 1980-01-03 to 1990-12-31. Largest 1% of simulated losses of Norwegian bank DNB.
data("fire") data("DNB")
data("fire") data("DNB")
fire
:univariate xts
object with 2167
observations.
DNB
:(25000, 3)-matrix
containing the
largest 1% of simulated (market risk, credit risk, asset risk)
losses of DNB; see Aas and Puccetti (2014, Section 2).
Marius Hofert
fire
:Originally Mette Rytgaard (Copenhagen Re).
DNB
:Originally Kjersti Aas and Giovanni Puccetti.
Aas, K. and Puccetti, G. (2014). Bounds for total economic capital: the DNB case study. Extremes 17(4), 693–715.
library(xts) ## Danish fire losses data("fire") str(fire) stopifnot(inherits(fire, "xts"), length(fire) == 2167) plot.zoo(fire, ylab = "Fire insurance claim") ## Largest 1% of simulated DNB losses data("DNB") stopifnot(dim(DNB) == c(25000, 3))
library(xts) ## Danish fire losses data("fire") str(fire) stopifnot(inherits(fire, "xts"), length(fire) == 2167) plot.zoo(fire, ylab = "Fire insurance claim") ## Largest 1% of simulated DNB losses data("DNB") stopifnot(dim(DNB) == c(25000, 3))
Single stock data; only Radioshack at the moment.
data("RSHCQ")
data("RSHCQ")
An xts
object containing adjusted close prices of
Radioshack (RSHCQ
; ticker symbol “RSHCQ”) from 1982-01-04 to 2015-01-20.
Marius Hofert
Radioshack defaulted early 2015. Yahoo Finance did not provide
adjusted close prices thereafter. We thus used the adjusted close
prices from 1982-01-04 to 2015-01-20 which we drew from Yahoo Finance
on 2015-01-21 via the function get_data()
from
qrmtools.
data("RSHCQ")
data("RSHCQ")
Single stock indices.
data("SP500") data("DJ") data("NASDAQ") data("FTSE") data("SMI") data("EURSTOXX") data("CAC") data("DAX") data("CSI") data("HSI") data("SSEC") data("NIKKEI")
data("SP500") data("DJ") data("NASDAQ") data("FTSE") data("SMI") data("EURSTOXX") data("CAC") data("DAX") data("CSI") data("HSI") data("SSEC") data("NIKKEI")
xts
objects containing adjusted close prices of the
S&P 500 (SP500
; ticker symbol “^GSPC”),
Dow Jones (DJ
; ticker symbol “^DJI”),
NASDAQ 100 (NASDAQ
; ticker symbol “^NDX”),
FTSE 100 (FTSE
; ticker symbol “^FTSE”),
Swiss Market Index (SMI
; ticker symbol “^SSMI”),
Euro Stoxx 50 (EURSTOXX
; ticker symbol “^STOXX50E”),
Cotation Assistée en Continu (CAC
; ticker symbol “^FCHI”),
Deutscher Aktienindex (DAX
; ticker sybmol “^GDAXI”),
China Securities Index (CSI
; ticker sybmol “000300.SS”),
Hang Seng Index (HSI
; ticker symbol “^HSI”),
Shanghai Stock Exchange Composite Index (SSEC
; ticker symbol
“000001.SS”) and the
NIKKEI (NIKKEI
; ticker symbol “^N225”)
from their first date of availablility to 2015-12-31.
Marius Hofert
The data was obtained from Yahoo Finance on 2016-01-03
via the function get_data()
from qrmtools.
data("SP500") data("DJ") data("NASDAQ") data("FTSE") data("SMI") data("EURSTOXX") data("CAC") data("DAX") data("CSI") data("HSI") data("SSEC") data("NIKKEI")
data("SP500") data("DJ") data("NASDAQ") data("FTSE") data("SMI") data("EURSTOXX") data("CAC") data("DAX") data("CSI") data("HSI") data("SSEC") data("NIKKEI")
Constituent data of various stock indices.
data("SP500_const") data("DJ_const") data("FTSE_const") data("EURSTX_const") data("HSI_const")
data("SP500_const") data("DJ_const") data("FTSE_const") data("EURSTX_const") data("HSI_const")
xts
objects containing adjusted close prices of the
constituents of the respective stock indices. These are
the S&P 500 constituents (SP500_const
with corresponding
Global Industry Classification Standard (GICS) information
SP500_const_info
; see
https://en.wikipedia.org/wiki/List_of_S%26P_500_companies;
given these tickers, the data was obtained from Yahoo! Finance)
as of 2015-10-12, the Dow Jones constituents (DJ_const
;
information about the constituents not available anymore)
as of 2016-01-03, the FTSE 100 constituents (FTSE_const
; see
https://uk.finance.yahoo.com/quote/%5EFTSE/components?ltr=1/) as of
2016-01-03 (the data was only available for 98 constituents),
the Euro Stoxx 50 constituents (EURSTX_const
; see
https://uk.finance.yahoo.com/quote/%5ESTOXX50E/components?ltr=1/)
as of 2016-01-03 (the data was only available for 98 constituents) and
the Hang Seng Index constituents (HSI_const
;
see https://uk.finance.yahoo.com/quote/%5EHSI/components?ltr=1/)
as of 2016-01-03.
The constituents data ranges from the first date at least one of the constituents is available (with missing data if not available) to 2015-12-31.
Marius Hofert
The data was obtained from the respective URLs
on 2016-01-03 via the function get_data()
from
qrmtools.
Note that for the S&P 500 constituents, the data was rounded to two decimal places to reduce the file size of the data set.
data("SP500_const") data("DJ_const") data("FTSE_const") data("EURSTX_const") data("HSI_const")
data("SP500_const") data("DJ_const") data("FTSE_const") data("EURSTX_const") data("HSI_const")
Chicago Board Options Exchange (CBOE) volatility index (VIX) data.
data("VIX")
data("VIX")
An xts
object containing the volatility index
(VIX
; ticker symbol “^VIX”) from its first date of availablility
to 2015-12-31.
The VIX is typically used as a market-based measure of volatility in percent.
Marius Hofert
The data was obtained from Yahoo Finance on 2016-01-03 via the
function get_data()
from qrmtools.
data("VIX")
data("VIX")