knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>",
  fig.path = "man/figures/README-",
  out.width = "100%"
)

firmValueSim

R-CMD-check Codecov test coverage

Overview

To minimize the downside of the assumptions made in an intrinsic valuation approach, the possibility exists to model the risk via a Monte Carlo simulation. Each variable in the model that is derived through assumption that can be stochastically modeled. The main purpose of a Monte Carlo in the context of a valuation is to achieve a risk management component, by integrating the expected value of multiple parameter outcomes. The two main approaches of risk management in valuation are either via a tree-based or simulation approach. The advantages of using simulations instead of decision-trees is that the flexibility of not only choosing a binary input approach, but instead choosing an underlying distribution. The first-step in the simulation is assigning a distribution of the variable, either through historical data, most likely outcome or market consensus. After the distributions are assigned, a single value of each parameter distribution gets sampled and the valuation is done as per usual.

Installation

devtools::install_github("maximilian-muecke/firmValueSim")

Usage

library(firmValueSim)
library(ggplot2)

# simulate stock prices via the Gordon Growth model
prices <- ddm_sim(
  1.5, r = 0.07, g_mu = 0.03, g_sigma = 0.01, n_sim = 10000, seed = 12345
)
# visualize distribution of prices
df <- data.frame(prices = prices)
ggplot(df, aes(x = prices)) +
  geom_histogram(binwidth = 5)

References



maximilian-muecke/firmValueSim documentation built on Oct. 2, 2022, 5:40 p.m.