Learn R Programming

FinancialInstrument (version 1.4.1)

ls_expiries: show unique expiration dates of instruments

Description

show unique expiration dates of instruments

Usage

ls_expiries(
  pattern = NULL,
  match = TRUE,
  underlying_id = NULL,
  type = "derivative"
)

ls_expires( pattern = NULL, match = TRUE, underlying_id = NULL, type = "derivative" )

Value

named chr vector with length of unique expiration dates of derivatives of class type and having an underlying_id of underlying_id if given.

Arguments

pattern

optional regular expression.

match

exact match?

underlying_id

chr name of underlying or vector of underlying_ids. If NULL, all underlyings will be used

type

chr string name of class that instruments to be returned must inherit.

Author

Garrett

Details

ls_expires is an alias. (plural of expires?)

type is currently only implemented for ‘derivative’, ‘future’, ‘option’, ‘call’ and ‘put’ internally, a call is made to the appropriate ls_ function.

See Also

ls_instruments_by for things like e.g. ls_instruments_by('expires','20110916'), ls_instruments, ls_derivatives, ls_options, ls_calls, buildHierarchy, instrument.table

Examples

Run this code

if (FALSE) {
option_series.yahoo('SPY')
option_series.yahoo('DIA',NULL)
ls_expiries()

}

Run the code above in your browser using DataLab