# Elliptic Lambda Distribution and Option Pricing Model

## Documentation for package ‘ecd’ version 0.9.2.4

- DESCRIPTION file.
- User guides, package vignettes and other documentation.

## Help Pages

B C D E H I J K L M N P Q R S W Y

ecd-package | ecd: A package for the stable lambda distribution family.

## -- B --

bootstrap | Bootstrap data for the Elliptic DB (ECDB)
bootstrap-method | Bootstrap data for the Elliptic DB (ECDB)
bootstrap.ecdb | Bootstrap data for the Elliptic DB (ECDB)

## -- C --

cfqsl | Stable lambda distribution
cfsl | Stable lambda distribution
cfstablecnt | Stable Count distribution
cfstdlap | Standardized Laplace process and distribution

## -- D --

dec | The Elliptic Distribution
discr | Discriminant of the elliptic curve y(x)
discr-method | Discriminant of the elliptic curve y(x)
discr.ecd | Discriminant of the elliptic curve y(x)
dlaplace0 | Laplace distribution
dqsl | Stable lambda distribution
dsl | Stable lambda distribution
dstablecnt | Stable Count distribution
dstdlap | Standardized Laplace process and distribution
dstdlap_poly | Standardized Laplace process and distribution

## -- E --

ecd | Constructor of ecd class
ecd-class | The ecd class
ecd.adj2gamma | Discriminant-adjusted gamma
ecd.adj_gamma | Discriminant-adjusted gamma
ecd.asymp_kurtosis | Compute asymptotic statistics of an ecd object
ecd.asymp_stats | Compute asymptotic statistics of an ecd object
ecd.ccdf | Complementary CDF of ecd
ecd.cdf | CDF of ecd
ecd.cubic | Generate or solve the cubic polynomial for ecd
ecd.cusp | Cusp constructor of ecd class
ecd.cusp_a2r | Conversion between alpha and gamma for cusp distribution
ecd.cusp_r2a | Conversion between alpha and gamma for cusp distribution
ecd.cusp_std_cf | The moments, characteristic function (CF), and moment generating function (MGF) of standard cusp distribution.
ecd.cusp_std_mgf | The moments, characteristic function (CF), and moment generating function (MGF) of standard cusp distribution.
ecd.cusp_std_moment | The moments, characteristic function (CF), and moment generating function (MGF) of standard cusp distribution.
ecd.data | Read sample data
ecd.data.arr | Read sample data
ecd.data.ts | Read sample data
ecd.data_stats | Statistics and histogram on log returns
ecd.dawson | Wrapper to convert numeric to mpfr
ecd.devel | Wrapper to convert numeric to mpfr
ecd.df2ts | Utility to standardize timeseries from data.frame to xts
ecd.diff | Utility to diff a vector of numeric or mpfr to get first derivative
ecd.erf | Wrapper to convert numeric to mpfr
ecd.erfc | Wrapper to convert numeric to mpfr
ecd.erfcx | Wrapper to convert numeric to mpfr
ecd.erfi | Wrapper to convert numeric to mpfr
ecd.erfq | Quartic scaled error function
ecd.erfq_sum | Quartic scaled error function
ecd.estimate_const | Estimate the normalization constant for an ecd object
ecd.fit_data | Sample data fit
ecd.fit_ts_conf | Timeseries fitting utility
ecd.gamma | Wrapper to convert numeric to mpfr
ecd.has_quantile | Whether the ecd object has quantile data or not
ecd.ifelse | Wrappers for ecd to maintain consistent type between mpfr and numeric
ecd.imgf | Incomplete MGF of ecd
ecd.integrate | Wrapper to integrate numeric and mpfr
ecd.kurt | Standard deviation, variance, mean, skewness, and kurtosis of ecd
ecd.kurtosis | Standard deviation, variance, mean, skewness, and kurtosis of ecd
ecd.lag | Utility to shift a vector of numeric or mpfr
ecd.manage_hist_tails | Manage histogram tails
ecd.max_kurtosis | Utility to calculate where the maximum kurtosis is on the positive j=0 line
ecd.mcsapply | Wrappers for ecd to maintain consistent type between mpfr and numeric
ecd.mean | Standard deviation, variance, mean, skewness, and kurtosis of ecd
ecd.mp1 | Wrapper to convert numeric to mpfr
ecd.mp2f | Wrapper to convert mpfr to numeric
ecd.mpfr | Wrapper to convert numeric to mpfr
ecd.mpfr_qagi | Utility to integrate mpfr with infinity via qagi
ecd.mpnum | Wrappers for ecd to maintain consistent type between mpfr and numeric
ecd.mppi | Wrapper to convert numeric to mpfr
ecd.mu_D | Incomplete MGF of ecd
ecd.ogf | Option generating function of ecd
ecd.pdf | Calculate the PDF of an ecd object
ecd.polar | Polar constructor of ecd class
ecd.rational | Utility to convert a numeric to a rational
ecd.read_csv_by_symbol | Read csv file of sample data
ecd.read_symbol_conf | Read conf for sample data
ecd.sapply | Wrappers for ecd to maintain consistent type between mpfr and numeric
ecd.sd | Standard deviation, variance, mean, skewness, and kurtosis of ecd
ecd.setup_const | Integration preprocessor for an ecd object
ecd.skewness | Standard deviation, variance, mean, skewness, and kurtosis of ecd
ecd.solve_cusp_asym | Trigonometric solution for asymmetric cusp distribution
ecd.stats | Compute statistics of an ecd object
ecd.toString | String representation of ecd
ecd.ts_lag_stats | Lag statistics on timeseries of log returns
ecd.uniroot | Uniroot wrapper
ecd.var | Standard deviation, variance, mean, skewness, and kurtosis of ecd
ecd.y0_isomorphic | The analytic solution of y(0) via isomorphic mapping.
ecdattr | Constructor of 'ecdattr' class for the Elliptic Database (ECDB)
ecdattr-class | An S4 class to represent the 'ecdattr' row in the Elliptic Database (ECDB)
ecdattr.enrich | Enrich a basic 'ecdattr' object
ecdattr.pairs | Create a list of basic 'ecdattr' objects
ecdattr.pairs_polar | Create a list of basic 'ecdattr' objects in polar coordinate
ecdb | Constructor of ecdb class for the elliptic database
ecdb-class | setClass for ecdb class
ecdb.dbSendQuery | Send query to the elliptic database
ecdb.protectiveCommit | Protective commit
ecdq | Constructor of ecdq class
ecdq-class | setClass for ecdq class
ecld | Constructor of ecld class
ecld-class | An S4 class to represent the lambda distribution
ecld.ccdf | CDF and CCDF of ecld
ecld.cdf | CDF and CCDF of ecld
ecld.cdf_gamma | CDF and CCDF of ecld
ecld.cdf_integrate | CDF and CCDF of ecld
ecld.const | Analytic solution of the normalization constant for lambda distribution
ecld.fixed_point_atm_ki | The Q operator in option pricing model
ecld.fixed_point_atm_Q_left | The Q operator in option pricing model
ecld.fixed_point_atm_Q_right | The Q operator in option pricing model
ecld.fixed_point_shift | The Q operator in option pricing model
ecld.fixed_point_SN0_atm_ki | The ATM RNO related constants and calculations in fixed point model
ecld.fixed_point_SN0_atm_ki_sd | The ATM RNO related constants and calculations in fixed point model
ecld.fixed_point_SN0_lambda_skew_ratio | The ATM RNO related constants and calculations in fixed point model
ecld.fixed_point_SN0_rho_sd | The ATM RNO related constants and calculations in fixed point model
ecld.fixed_point_SN0_skew | The ATM RNO related constants and calculations in fixed point model
ecld.from | Constructor of ecld class
ecld.from_sd | Constructor of ecld class
ecld.gamma | Incomplete gamma function and asymptotic expansion
ecld.gamma_2F0 | Incomplete gamma function and asymptotic expansion
ecld.gamma_hgeo | Incomplete gamma function and asymptotic expansion
ecld.ifelse | Wrappers for ecld to maintain consistent type between mpfr and numeric
ecld.imgf | Incomplete moment generating function (IMGF) of ecld
ecld.imgf_gamma | Incomplete moment generating function (IMGF) of ecld
ecld.imgf_integrate | Incomplete moment generating function (IMGF) of ecld
ecld.imgf_quartic | Incomplete moment generating function (IMGF) of ecld
ecld.imnt | Incomplete moment (imnt) of ecld
ecld.imnt_integrate | Incomplete moment (imnt) of ecld
ecld.imnt_sum | Incomplete moment (imnt) of ecld
ecld.ivol_ogf_star | Calculate implied volatility using star OGF and small sigma formula
ecld.kurt | Compute statistics analytically for an ecld object
ecld.kurtosis | Compute statistics analytically for an ecld object
ecld.laplace_B | Analytic solution for y(x) in lambda distribution
ecld.mclapply | Wrappers for ecld to maintain consistent type between mpfr and numeric
ecld.mean | Compute statistics analytically for an ecld object
ecld.mgf | The moments and MGF of ecld
ecld.mgf_by_sum | The moments and MGF of ecld
ecld.mgf_diterm | The term structure of ecld symmetric MGF
ecld.mgf_quartic | The moments and MGF of ecld
ecld.mgf_term | The term structure of ecld symmetric MGF
ecld.mgf_term_original | The term structure of ecld symmetric MGF
ecld.mgf_trunc | The term structure of ecld symmetric MGF
ecld.mgf_trunc_max_sigma | The term structure of ecld symmetric MGF
ecld.moment | The moments and MGF of ecld
ecld.mpnum | Wrappers for ecld to maintain consistent type between mpfr and numeric
ecld.mu_D | mu_D of ecld
ecld.mu_D_by_sum | mu_D of ecld
ecld.mu_D_integrate | mu_D of ecld
ecld.mu_D_quartic | mu_D of ecld
ecld.ogf | Option generating function (OGF) of ecld
ecld.ogf_gamma | Option generating function (OGF) of ecld
ecld.ogf_imnt_sum | Option generating function (OGF) of ecld
ecld.ogf_integrate | Option generating function (OGF) of ecld
ecld.ogf_log_slope | Option generating function (OGF) of ecld
ecld.ogf_quartic | Option generating function (OGF) of ecld
ecld.ogf_star | Star OGF of ecld
ecld.ogf_star_analytic | Star OGF of ecld
ecld.ogf_star_exp | Star OGF of ecld
ecld.ogf_star_gamma_star | Star OGF of ecld
ecld.ogf_star_hgeo | Star OGF of ecld
ecld.op_O | The O, V, U operators in option pricing model
ecld.op_Q | The Q operator in option pricing model
ecld.op_Q_skew | The Q operator in option pricing model
ecld.op_Q_skew_by_k_lm | The Q operator in option pricing model
ecld.op_U_lag | The O, V, U operators in option pricing model
ecld.op_V | The O, V, U operators in option pricing model
ecld.op_VL_quartic | The O, V, U operators in option pricing model
ecld.pdf | Calculate the PDF of an ecld object
ecld.quartic | Constructor of ecld class
ecld.quartic_model_sample | Calculate ATM attributes from key quartic parameters
ecld.quartic_model_sample_attr | Calculate ATM attributes from key quartic parameters
ecld.quartic_Q | The ATM volatility and skew of Q_p in quartic model
ecld.quartic_Qp | The ATM volatility and skew of Q_p in quartic model
ecld.quartic_Qp_atm_attr | Calculate ATM attributes from key quartic parameters
ecld.quartic_Qp_atm_ki | The ATM volatility and skew of Q_p in quartic model
ecld.quartic_Qp_atm_skew | The ATM volatility and skew of Q_p in quartic model
ecld.quartic_Qp_rho | The ATM volatility and skew of Q_p in quartic model
ecld.quartic_Qp_skew | The ATM volatility and skew of Q_p in quartic model
ecld.quartic_SN0_atm_ki | The ATM RNO related constants and calculations in quartic model
ecld.quartic_SN0_max_RNV | The ATM RNO related constants and calculations in quartic model
ecld.quartic_SN0_rho_stdev | The ATM RNO related constants and calculations in quartic model
ecld.quartic_SN0_skew | The ATM RNO related constants and calculations in quartic model
ecld.sapply | Wrappers for ecld to maintain consistent type between mpfr and numeric
ecld.sd | Compute statistics analytically for an ecld object
ecld.sged_cdf | The integral solutions of SGED
ecld.sged_const | The integral solutions of SGED
ecld.sged_imgf | The integral solutions of SGED
ecld.sged_mgf | The integral solutions of SGED
ecld.sged_moment | The integral solutions of SGED
ecld.sged_ogf | The integral solutions of SGED
ecld.skewness | Compute statistics analytically for an ecld object
ecld.solve | Analytic solution for y(x) in lambda distribution
ecld.solve_by_poly | Analytic solution for y(x) in lambda distribution
ecld.solve_isomorphic | Analytic solution for y(x) in lambda distribution
ecld.solve_quartic | Analytic solution for y(x) in lambda distribution
ecld.validate | Constructor of ecld class
ecld.var | Compute statistics analytically for an ecld object
ecld.y_slope | Analytic solution for the slope of y(x) in lambda distribution
ecld.y_slope_trunc | Analytic solution for the slope of y(x) in lambda distribution
ecldOrEcd-class | The ecldOrEcd class
ecop-class | An S4 class to represent the top-level option model
ecop.bs_call_price | Calculate option price from implied volatility in Black-Sholes model
ecop.bs_implied_volatility | Implied volatility of Black-Sholes model
ecop.bs_option_price | Calculate option price from implied volatility in Black-Sholes model
ecop.bs_put_price | Calculate option price from implied volatility in Black-Sholes model
ecop.build_opt | Constructor of ecop class by read conf for option sample data
ecop.enrich_option_df | Read option data csv
ecop.find_fixed_point_lambda_by_atm_skew | Utility to find the fixed point lambda that matches ATM skew
ecop.find_fixed_point_sd_by_lambda | Utility to find the fixed point stdev when lambda is given
ecop.from_symbol_conf | Constructor of ecop class by read conf for option sample data
ecop.get_ld_triple | Get triple list of ecld objects by stdev
ecop.opt-class | An S4 class to represent the option data and model calculation
ecop.polyfit_option | Poly fit on option prices
ecop.read_csv_by_symbol | Read option data csv
ecop.read_symbol_conf | Constructor of ecop class by read conf for option sample data
ecop.smile_data_calculator | Master calculator for all the analytics of volatility smiles required for a date
ecop.term_atm | Master calculator for all the analytics of volatility smiles required for a date
ecop.term_idx_range | Produce 3x3 plot of volatility smiles for a date
ecop.term_master_calculator | Master calculator for all the analytics of volatility smiles required for a date
ecop.term_plot_3x3 | Produce 3x3 plot of volatility smiles for a date
ecop.term_realized_days | Produce 3x3 plot of volatility smiles for a date
ecop.term_target_days_default | Produce 3x3 plot of volatility smiles for a date
ecop.vix_plot_3x3 | Produce 3x3 plot of VIX volatility smiles for a date
ellipticity | Ellipticity of ecd object
ellipticity-method | Ellipticity of ecd object
ellipticity.ecd | Ellipticity of ecd object

## -- H --

history | List of history in the Elliptic DB
history-method | List of history in the Elliptic DB
history.ecdb | List of history in the Elliptic DB

## -- I --

integrate_pdf | Integrate a function with PDF of the distribution
integrate_pdf-method | Integrate a function with PDF of the distribution
integrate_pdf.ecd | Integrate a function with PDF of the distribution

## -- J --

jinv | J-invariant of the elliptic curve y(x)
jinv-method | J-invariant of the elliptic curve y(x)
jinv.ecd | J-invariant of the elliptic curve y(x)

## -- K --

k2mnt | Conversion between cumulants and moments
kqsl | Stable lambda distribution
ksl | Stable lambda distribution
kstablecnt | Stable Count distribution
kstdlap | Standardized Laplace process and distribution

## -- L --

lamp | Constructor of lamp class
lamp-class | An S4 class to represent the lambda process
lamp.generate_tau | Generate tau from stable distribution
lamp.plot_sim4 | Plot the simulation result in standard layout
lamp.plot_sim6 | Plot the simulation result in standard layout
lamp.qsl_fit_config | Read QSLD fit config
lamp.qsl_fit_config_xtable | Read QSLD fit config
lamp.qsl_fit_plot | Plot the fit to asset returns using quartic stable lambda distribution
lamp.sd_factor | Calculate sd adjustment factor
lamp.simulate1 | Simulate one sequence of lambda process from stable distribution
lamp.simulate_iter | Simulate lambda process from stable distribution iteratively
lamp.stable_rnd_walk | Calculate the stable random walk
levy.dlambda | Standard Lambda distribution
levy.domain_coloring | Domain coloring of Laplace kernel of lambda distribution
levy.dskewed | Skewed Levy distribution in Levy statistics

## -- M --

mnt2k | Conversion between cumulants and moments
moment | Compute the moment of ecd via integration
moment-method | Compute the moment of ecd via integration
moment.ecd | Compute the moment of ecd via integration

## -- N --

numericMpfr-class | The numericMpfr class

## -- P --

pec | The Elliptic Distribution
plot_2x2 | Standard 2x2 plot for sample data
plot_2x2-method | Standard 2x2 plot for sample data
plot_2x2.ecd | Standard 2x2 plot for sample data
pqsl | Stable lambda distribution
psl | Stable lambda distribution
pstablecnt | Stable Count distribution
pstdlap | Standardized Laplace process and distribution

## -- Q --

qec | The Elliptic Distribution
qqsl | Stable lambda distribution
qsl | Stable lambda distribution
qsld | Constructor of sld class
qsld.fit | Fit observations to QSLD via MLE
qsl_kurtosis_analytic | Analytic solutions on the statistics of quartic stable lambda distribution
qsl_pdf_integrand_analytic | Analytic solutions on the statistics of quartic stable lambda distribution
qsl_skewness_analytic | Analytic solutions on the statistics of quartic stable lambda distribution
qsl_std_pdf0_analytic | Analytic solutions on the statistics of quartic stable lambda distribution
qsl_variance_analytic | Analytic solutions on the statistics of quartic stable lambda distribution
qstablecnt | Stable Count distribution
qstdlap | Standardized Laplace process and distribution
quantilize | Add the quantile data to the ecd object
quantilize-method | Add the quantile data to the ecd object
quantilize.ecd | Add the quantile data to the ecd object

## -- R --

read | Read API for the ecdb
read-method | Read API for the ecdb
read.ecdb | Read API for the ecdb
rec | The Elliptic Distribution
rlaplace0 | Laplace distribution
rqsl | Stable lambda distribution
rsl | Stable lambda distribution
rstablecnt | Stable Count distribution
rstdlap | Standardized Laplace process and distribution

## -- S --

sld | Constructor of sld class
sld-class | An S4 class to represent the stable lambda distribution
sld.kurt | Compute statistics analytically for an sld object
sld.kurtosis | Compute statistics analytically for an sld object
sld.mean | Compute statistics analytically for an sld object
sld.sd | Compute statistics analytically for an sld object
sld.skewness | Compute statistics analytically for an sld object
sld.var | Compute statistics analytically for an sld object
solve-method | Solve the elliptic curve y(x)
solve.ecd | Solve the elliptic curve y(x)
solve_sym | Analytic solution for a symmetric elliptic curve
solve_sym-method | Analytic solution for a symmetric elliptic curve
solve_sym.ecd | Analytic solution for a symmetric elliptic curve
solve_trig | Trigonometric solution for a elliptic curve
solve_trig-method | Trigonometric solution for a elliptic curve
solve_trig.ecd | Trigonometric solution for a elliptic curve
summary | Summary for the Elliptic DB (ECDB)
summary-method | Summary for the Elliptic DB (ECDB)
summary.ecdb | Summary for the Elliptic DB (ECDB)

## -- W --

write | Write API for the ecdb for a list of basic ecdattr objects
write-method | Write API for the ecdb for a list of basic ecdattr objects
write.ecdb | Write API for the ecdb for a list of basic ecdattr objects

## -- Y --

y_slope | Slope of y(x)
y_slope-method | Slope of y(x)
y_slope.ecd | Slope of y(x)