NAME
Quant::Framework::Dividend - A module to save/load dividends
DESCRIPTION
This module saves/loads dividends data to/from Chronicle. To save dividends for a company:
my $corp_dividends = Quant::Framework::Dividends->new(symbol => $symbol, rates => { 1 => 0, 2 => 1, 3=> 0.04 } discrete_points => { '2015-04-24' => 0, '2015-09-09' => 0.134 }); $corp_dividends->save;
To read dividends information for a company:
my $corp_dividends = Quant::Framework::Dividends->new(symbol => $symbol);
my $rates = $corp_dividends->rates;
my $disc_points = $corp_dividends->discrete_points;
underlying_config
Used for more advanced query of Dividen. For simple `rate_for` queries, this is not required.
for_date
The date for which we wish data
save
Saves dividend data to the provided Chronicle storage
recorded_date
The date (and time) that the dividend was recorded, as a Date::Utility.
discrete_points
The discrete dividend points received from provider.
rate_for
Returns the rate for a particular timeinyears for symbol. ->rate_for(7/365)
dividend_rate_for
Get the dividend rate for this underlying over a given time period (expressed in timeinyears.)
get_discrete_dividend_for_period
Returns discrete dividend for the given (start,end) dates and dividend recorded date for the underlying specified using `underlying_config`
dividend_adjustments_for_period
Returns dividend adjustments for given start/end period