europeanCallOptionValue: Estimate European Call Option Value

View source: R/europeanCallOptionValue.R

europeanCallOptionValueR Documentation

Estimate European Call Option Value

Description

This function calculates the value of a European call option based on stock data, a future time value, and a buy value

Usage

europeanCallOptionValue(
  stock_data,
  future_time,
  buy_value,
  max.p = 5,
  max.q = 5,
  method = "CSS-ML"
)

Arguments

stock_data

Numeric vector of stock prices data

future_time

Numeric constant of the future time

buy_value

The numeric buy value of the European call option

max.p

The maximum order of the autoregressive part of the ARMA model (default is set to 5)

max.q

The maximum order of the moving average part of the ARMA model (default is set to 5)

method

The way that the ARMA model is calculated, accepted values are "ML", "CSS-ML" and "CSS"

Value

Estimate the value of a European call option, determine the probability of making profits, and model an appropriate ARMA model for the given stock data

Examples

library(stats)
library(forecast)
# Create simulated data
n = 100
set.seed(42)
arma_values = arima.sim(n = n, model = list(ar = c(0.5), ma = c(0.5, -0.5)))
linear_model = 5 +  1:n
stock_data = arma_values + linear_model
buy_value = 105
future_time = 1
europeanCallOptionValue(stock_data = stock_data, future_time, buy_value, max.p = 5, max.q = 5)


armaOptions documentation built on Aug. 31, 2025, 1:07 a.m.