Nothing
#'Displays graph of the Initial Value as Net Debit (V0Dr) per share or unit of the underlying on initiation day for European Put Buyer in the Plots tab.
#'@details
#'According to conceptual details given by Cohen (2015), and a closed-form solution provided by Kakushadze and Serur (2018), this method is developed, and the given examples are created, to display the Initial Value as Net Debit (V0Dr) per share or unit of the underlying on initiation day for European Put Buyer. EXAMPLE, Buying HypoTech December 10 put at $2.00. Here, \code{X} is the exercise price (strike price) of the option, \code{ST} is the price of the underlying at time T, and \code{C} is the price (also called premium) paid by the European Call Buyer to the Call Seller. For a Put Buyer there is outflow of cash in the form of premium paid for buying the right to sell and hence it is a Net Debit Position that is represented by V0Dr.
#'@param ST Spot Price at time T.
#'@param X Strike Price or eXercise price.
#'@param P Put Premium or Put price.
#'@param hl lower bound value for setting lower-limit of x-axis displaying spot price.
#'@param hu upper bound value for setting upper-limit of x-axis displaying spot price.
#'@param xlab X-axis label.
#'@param ylab Y-axis label.
#'@param main Title of the Graph.
#'@return Returns a graph of the strategy.
#'@importFrom graphics abline
#'@importFrom graphics text
#'@importFrom graphics lines
#'@importFrom graphics par
#'@importFrom graphics plot
#'@author MaheshP Kumar, \email{maheshparamjitkumar@@gmail.com}
#'@references
#'Chance,D.M.(2019). Basics of Derivative Pricing and Valuation. In CFA Program Curriculum 2020 Level I Volumes 1-6. (Vol. 5, pp. 385-453). Wiley Professional Development (P&T). ISBN 9781119593577, https://bookshelf.vitalsource.com/books/9781119593577\cr
#'Cohen, G. (2015). The Bible of Options Strategies (2nd ed.). Pearson Technology Group. https://bookshelf.vitalsource.com/books/9780133964448\cr
#'Kakushadze, Z., & Serur, J. A. (2018, August 17). 151 Trading Strategies. Palgrave Macmillan. https://papers.ssrn.com/sol3/papers.cfm?abstract_id=3247865
#'@examples
#'longPutInitialValueV0(10,10,2)
#'longPutInitialValueV0(40,40,3,0.8,1.2)
#'@export
longPutInitialValueV0<-function (ST,X,P,hl=0,hu=1.5,xlab="Spot Price ($) at Expiration",ylab=" Initial Value [ V0] ($)",main="Long Put / Put Buyer V0 [Dr/Cr]"){
myData <- data.frame (spot = c((ST*hl):(ST*hu)))
oldpar <- par(no.readonly = TRUE)
on.exit(par(oldpar))
myData$Val <- (pmax(0,P))
myData$Val = round(myData$Val, digits=2)
myData$spot = round(myData$spot, digits=2)
par(mfrow = c(1,1))
plot(myData$spot, myData$Val, pch=21, bg="gold",col="gold",cex=1.1, xlab = xlab, ylab = ylab, col.lab="blue",main = main,xlim=c(ST*hl,ST*hu), ylim=c(-1,P+2))
text (myData$spot, myData$Val, labels = as.character(myData$Val), adj = 2,
pos = NULL, offset = 0.5, vfont = NULL,
cex = 0.7, col = "red", font = NULL )
text(X+2.5,P+0.25, labels=as.character("V0Dr = Net Debit ( Premium paid )"), adj = 1,pos = NULL, offset = 0.5, vfont = NULL,
cex = 0.9, col = "darkblue", font = NULL )
text(X+1.75,P-0.25, labels=as.character("Bearish OUTLOOK"), adj = 1,pos = NULL, offset = 0.5, vfont = NULL,
cex = 1, col = "brown", font = NULL )
abline(h = 0,col = "gray")
abline(v = X,col = "gray")
legend("topright", legend = "V0Dr ",text.col ="snow", bg ="violetred4", pch=16, col="gold",cex = 1.1)
lines(myData$spot,myData$Val,col = "blue")
}
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.