getStops: Generates VALOS stops

Description Usage Arguments Details Note Examples

Description

Generate stops for a given stock using the SMIF's Volatility Adjusted Leg Out Strategy. Stops are generated as of a user given date which, if ommitted, defaults to the current date.

Usage

1
getStops(ticker, date = Sys.Date(), per = FALSE)

Arguments

ticker

Character; ticker of the stock to generate stops for

date

Character (or Date); date of the day to generate the VALOS stops. Defaults to Sys.Date() (today's date)

per

Logical; should the stops be returned in percentage terms. Defaults to TRUE

Details

Stops can be returned in percentage terms (i.e. c(-0.1, -0.2, -0.3)) or in dollar terms based on the most recent price available at the date the stops were generated (i.e. c(54, 48, 42)), in US dollars. Stops are calculated using the current official version of VALOS. This allows for the possibility of there being only one stop returned for the stock (as is allowed by our current version of VALOS).

Note

The SMIF VALOS formula is currently undergoing a review and a finalized change is likely before November 15th. After that, past VALOS stops calculated by this function may or may not return the old version of VALOS or the newer version of VALOS. Post-revision runnings for date >= date(revision) will use the newer VALOS formula.

Examples

1
2
3
## Not run: 
valos("CELG", per = TRUE)
## End(Not run)

alec25/smif.package documentation built on May 22, 2019, 12:36 p.m.