Payoff of solar options on historical data
solarOption_historical(
model,
data = NULL,
nmonths = 1:12,
put = TRUE,
control_options = control_solarOption()
)An object with the class solarModel. See the function solarModel for details.
Optional dataset for the computation of the payoff.
Numeric vector, months in which the payoff should be computed. Can vary from 1 (January) to 12 (December).
Logical, when TRUE, the default, will be computed the price for a put contract, otherwise for a call contract.
Named list with control parameters. See control_solarOption for more details.
An object of the class solarOptionPayoff.
Version 1.0.0.
# Solar model
model <- solarModel$new(spec)
model$fit()
#> No outliers!
# Historical payoff (put)
solarOption_historical(model, put=TRUE)
#> ------------------------ Solar Option Payoffs (put) ------------------------
#> Yearly payoff: 183.73
#> Monthly payoffs:
#> Jan: 7.40 Feb: 11.0 Mar: 15.5
#> Apr: 21.8 May: 30.7 Jun: 22.9
#> Jul: 13.6 Ago: 13.2 Sep: 14.6
#> Oct: 15.0 Nov: 11.4 Dec: 6.63
# Historical payoff (call)
solarOption_historical(model, put=FALSE)
#> ------------------------ Solar Option Payoffs (call) ------------------------
#> Yearly payoff: 211.67
#> Monthly payoffs:
#> Jan: 11.4 Feb: 17.8 Mar: 25.5
#> Apr: 24.5 May: 19.6 Jun: 17.3
#> Jul: 20.1 Ago: 21.4 Sep: 18.9
#> Oct: 14.6 Nov: 10.1 Dec: 10.3