CalcEuroLotteryPnL: PnL calculation for EuroMillions/EuroJackpot backtesting

View source: R/CalcEuroLotteryPnL.R

CalcEuroLotteryPnLR Documentation

PnL calculation for EuroMillions/EuroJackpot backtesting

Description

Calculates the PnL for a pay out structure created during backtesting

Usage

CalcEuroLotteryPnL(backtested_results, plot_results = FALSE)

Arguments

backtested_results

The EuroMillions/EuroJackpot results backtested against the user input

plot_results

(Optional) If TRUE, the P&L historical graphs are plotted, default FALSE

Value

PnL figures

Author(s)

Tasos Grivas <tasos@openriskcalculator.com>

Examples


euromillions_results = EuroMillionsResults()
user_input = c(10,20,30,40,50,5,10)
backtested_results = EuroLotteryBacktesting(euromillions_results, '2005-01-01', user_input)
pnl_result = CalcEuroLotteryPnL(backtested_results, plot_results = TRUE)

sa-ccr/Trading documentation built on Feb. 23, 2024, 9:26 p.m.