{"action":"created","comment":{"url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/comments/72384013","id":72384013,"diff_hunk":"@@ -0,0 +1,663 @@\n+package Quant::Framework::Spot::DatabaseAPI;\n+\n+=head1 NAME\n+\n+Quant::Framework::Spot::DatabaseAPI\n+\n+=head1 DESCRIPTION\n+\n+The API class which we can query feed database.\n+\n+This class acts as a facade to the functions available in the DB. That is to say that that actual API is expressed by the functions in the DB. \n+\n+Each function available here has a function with same name inside the db.\n+\n+If any of the functions fail due to any reason it will cause an exception thrown straight from DBI layer.\n+\n+=cut\n+\n+use Moose;\n+use DateTime;\n+use Date::Utility;\n+use Quant::Framework::Spot::Tick;\n+use Quant::Framework::Spot::OHLC;\n+\n+has db_handle => (\n+    is       => 'ro',\n+    required => 1,\n+);\n+\n+=head2 default_prefix\n+\n+The prefix used to create name of the table `feed.tick` which will contain spot, timestamp and underlying columns.\n+\n+=cut\n+\n+has default_prefix => (\n+    is      => 'ro',\n+    default => 'feed.',\n+);\n+\n+=head2 dbh\n+\n+Return database handle. If db_handle is a normal reference, it will be used directly.\n+If it is a code-ref, it will be invoked to get the database handle.\n+\n+=cut\n+\n+sub dbh {\n+    my $self = shift;\n+\n+    if (ref($self->db_handle) eq 'CODE') {\n+        return $self->db_handle->();\n+    }\n+\n+    return $self->db_handle;\n+}\n+\n+=head2 underlying\n+\n+The underlying symbol for which this API will fetch data\n+\n+=cut\n+\n+has underlying => (\n+    is       => 'ro',\n+    isa      => 'Str',\n+    required => 1,\n+);\n+\n+=head2 invert_values\n+\n+If this argument is set, all tick and OHLC data will have their value inverted. This is useful when we have EURUSD feeds information but\n+want to have data for USDEUR underlying.\n+\n+=cut\n+\n+has 'invert_values' => (\n+    is => 'ro',\n+);\n+\n+=head2 use_official_ohlc\n+\n+In case there are official and non-official OHLC values for an underlying, this flag specifies which type of data we want\n+\n+=cut\n+\n+has use_official_ohlc => (\n+    is => 'ro',\n+);\n+\n+=head2 tick_at_for_interval\n+\n+Returns ticks in the given interval.\n+\n+=cut\n+\n+sub tick_at_for_interval {\n+    my $self = shift;\n+    my $args = shift;\n+\n+    my $start_time = $args->{start_date}->datetime_yyyymmdd_hhmmss;\n+    my $end_time   = $args->{end_date}->datetime_yyyymmdd_hhmmss;\n+    my $interval   = $args->{interval_in_seconds};\n+\n+    my $statement = $self->dbh->prepare_cached('SELECT * FROM tick_at_for_interval($1, $2, $3, $4)', {}, 3);\n+    $statement->bind_param(1, $self->underlying);\n+    $statement->bind_param(2, $start_time);\n+    $statement->bind_param(3, $end_time);\n+    $statement->bind_param(4, $interval);\n+\n+    return $self->_query_ticks($statement);\n+}\n+\n+=head1 METHODS\n+\n+=head2 ticks_start_end\n+\n+get ticks from feed db filtered by\n+    - start_time, end_time - All ticks between <start_time> and <end_time>\n+\n+Returns\n+     ArrayRef[Quant::Framework::Spot::Tick]\n+\n+=cut\n+\n+sub ticks_start_end {\n+    my $self = shift;\n+    my $args = shift;\n+\n+    my $start_time;\n+    my $end_time;\n+    $start_time = Date::Utility->new($args->{start_time})->datetime_yyyymmdd_hhmmss\n+        if ($args->{start_time});\n+    $end_time = Date::Utility->new($args->{end_time})->datetime_yyyymmdd_hhmmss\n+        if ($args->{end_time});\n+\n+    my $statement = $self->dbh->prepare_cached('SELECT * FROM ticks_start_end($1, $2, $3)', {}, 3);\n+    $statement->bind_param(1, $self->underlying);\n+    $statement->bind_param(2, $start_time);\n+    $statement->bind_param(3, $end_time);\n+\n+    return $self->_query_ticks($statement);\n+}\n+\n+=head2 get_first_tick\n+\n+Find the first tick which breaches a barrier\n+\n+=cut\n+\n+sub get_first_tick {\n+    my ($self, %args) = @_;\n+\n+    my $underlying    = $args{underlying};\n+    my $system_symbol = $args{system_symbol};\n+    my $pipsize       = $args{pip_size};\n+    my $start_time    = Date::Utility->new($args{start_time})->db_timestamp;\n+    my $end_time      = Date::Utility->new($args{end_time} // time)->db_timestamp;\n+    my @sql_args      = ($system_symbol, $start_time, $end_time);\n+    my $sql =\n+        'SELECT EXTRACT(epoch FROM ts) AS epoch, spot FROM ' . ($self->default_prefix // '') . 'tick WHERE underlying = $1 AND ts >= $2 AND ts <= $3';\n+\n+    my $next = 4;\n+    my @barriers;\n+    if ($args{higher}) {\n+        push @barriers, \"spot > \\$$next\";\n+        push @sql_args, $args{higher} - $pipsize / 2;\n+        $next++;\n+    }\n+    if ($args{lower}) {\n+        push @barriers, \"spot < \\$$next\";\n+        push @sql_args, $args{lower} + $pipsize / 2;\n+        $next++;\n+    }\n+    unless (@barriers) {\n+        die \"At least one of higher or lower must be specified\";\n+    }\n+    $sql .= \" AND (\" . join(\" OR \", @barriers) . q[) ORDER BY ts ASC LIMIT 1];\n+\n+    my $statement = $self->dbh->prepare_cached($sql, {}, 3);\n+    foreach my $which_param (1 .. scalar @sql_args) {\n+\n+        # There has to be a more reasonable standard way to do this.\n+        $statement->bind_param($which_param, $sql_args[$which_param - 1]);\n+    }\n+    my $tick;\n+    if (my ($epoch, $quote) = $self->dbh->selectrow_array($statement)) {\n+        $tick = Quant::Framework::Spot::Tick->new({\n+            symbol => $underlying,\n+            epoch  => $epoch,\n+            quote  => $quote,\n+        });\n+    }\n+\n+    $tick->invert_values if ($tick and $self->invert_values);\n+\n+    return $tick;\n+}\n+\n+=head2 ticks_start_limit\n+\n+get ticks from feed db filtered by\n+    - start_time, limit - <limit> number of ticks starting from <start_time>\n+\n+Returns\n+     ArrayRef[Quant::Framework::Spot::Tick]\n+\n+=cut\n+\n+sub ticks_start_limit {\n+    my $self = shift;\n+    my $args = shift;\n+\n+    my $start_time;\n+    $start_time = Date::Utility->new($args->{start_time})->datetime_yyyymmdd_hhmmss\n+        if ($args->{start_time});\n+\n+    my $statement = $self->dbh->prepare_cached('SELECT * FROM ticks_start_limit($1, $2, $3)', {}, 3);\n+    $statement->bind_param(1, $self->underlying);\n+    $statement->bind_param(2, $start_time);\n+    $statement->bind_param(3, $args->{limit});\n+\n+    my $ticks = $self->_query_ticks($statement);\n+\n+    # It would probably be more efficient to do this at the db level, but\n+    # I don't have that luxury at present.\n+    if ($args->{end_time}) {\n+        my $end_epoch = Date::Utility->new($args->{end_time})->epoch;\n+        $ticks = [grep { $_->epoch <= $end_epoch } @{$ticks}];\n+    }\n+\n+    return $ticks;\n+}\n+\n+=head2 ticks_end_limit\n+\n+get ticks from feed db filtered by\n+    - end_time, limit - <limit> number ticks before <end_time>\n+\n+Returns\n+     ArrayRef[Quant::Framework::Spot::Tick]\n+\n+=cut\n+\n+sub ticks_end_limit {\n+    my $self = shift;\n+    my $args = shift;\n+\n+    my $end_time;\n+    $end_time = Date::Utility->new($args->{end_time})->datetime_yyyymmdd_hhmmss\n+        if ($args->{end_time});\n+\n+    my $statement = $self->dbh->prepare_cached('SELECT * FROM ticks_end_limit($1, $2, $3)', {}, 3);\n+    $statement->bind_param(1, $self->underlying);\n+    $statement->bind_param(2, $end_time);\n+    $statement->bind_param(3, $args->{limit});\n+\n+    return $self->_query_ticks($statement);\n+}\n+\n+=head2 tick_at\n+\n+get a valid tick at time given or not a valid tick before a given time. Accept argument\n+    - end_time - Time at which we want the tick\n+    - allow_inconsistent - if this is passed then we get the last available tick, we do not care if its a valid ick or not.\n+\n+Returns\n+     Quant::Framework::Spot::Tick\n+\n+=cut\n+\n+sub tick_at {\n+    my $self = shift;\n+    my $args = shift;\n+    my $tick;\n+\n+    return unless ($args->{end_time});\n+    my $end_time = Date::Utility->new($args->{end_time});\n+\n+    my $sql =\n+        ($args->{allow_inconsistent})\n+        ? 'SELECT * FROM tick_at_or_before($1, $2::TIMESTAMP)'\n+        : 'SELECT * FROM consistent_tick_at_or_before($1, $2::TIMESTAMP)';\n+    my $statement = $self->dbh->prepare_cached($sql, {}, 3);\n+    $statement->bind_param(1, $self->underlying);\n+    $statement->bind_param(2, $end_time->db_timestamp);\n+\n+    return $self->_query_single_tick($statement);\n+}\n+\n+=head2 tick_after\n+\n+get tick from feed db after the time given.\n+    - start_time - the first tick after <start_time>\n+\n+Returns\n+     ArrayRef[Quant::Framework::Spot::Tick]\n+\n+=cut\n+\n+sub tick_after {\n+    my $self = shift;\n+    my $time = shift;\n+    return unless ($time);\n+\n+    $time = Date::Utility->new($time);\n+\n+    my $statement = $self->dbh->prepare_cached('SELECT * FROM tick_after($1, $2)', {}, 3);\n+    $statement->bind_param(1, $self->underlying);\n+    $statement->bind_param(2, $time->datetime_yyyymmdd_hhmmss);\n+\n+    return $self->_query_single_tick($statement);\n+}\n+\n+=head2 ticks_start_end_with_limit_for_charting\n+\n+get ticks from feed db filtered by\n+    - start_time, end_time, limit - all ticks between <start_time> and <end_time> and limit to <limit> entries.\n+\n+Returns\n+     ArrayRef[Quant::Framework::Spot::Tick]\n+\n+=cut\n+\n+sub ticks_start_end_with_limit_for_charting {\n+    my $self = shift;\n+    my $args = shift;\n+\n+    my $start_time;\n+    my $end_time;\n+    $start_time = Date::Utility->new($args->{start_time})->datetime_yyyymmdd_hhmmss\n+        if ($args->{start_time});\n+    $end_time = Date::Utility->new($args->{end_time})->datetime_yyyymmdd_hhmmss\n+        if ($args->{end_time});\n+\n+    my $statement = $self->dbh->prepare_cached('SELECT * FROM ticks_start_end_with_limit_for_charting($1, $2, $3, $4)', {}, 3);\n+    $statement->bind_param(1, $self->underlying);\n+    $statement->bind_param(2, $start_time);\n+    $statement->bind_param(3, $end_time);\n+    $statement->bind_param(4, $args->{limit});\n+\n+    return $self->_query_ticks($statement);\n+}\n+\n+=head2 $self->ohlc_start_end(\\%args)\n+\n+This method returns reference to the list of OHLC for the specified period.\n+Accepts following arguments:\n+\n+=over 4\n+\n+=item B<start_time>\n+\n+Compute OHLC starting from the specified time. Note, that if I<start_time> is\n+not at the beginning of the unit used by the source table (minutes, hour, or\n+days depending on I<aggregation_period>) it will be aligned to the start of the\n+next unit. But timestamp of the returned OHLC may be pointing to earlier moment\n+of time, e.g. for weekly and monthly OHLC it will point to the start of week or\n+month, even though actual OHLC value may be computed from the middle of week or\n+month.\n+\n+=item B<end_time>\n+\n+Compute OHLC till specified time. Note, that it will be aligned so timestamp\n+would be multiple of I<aggregation_period>.\n+\n+=item B<aggregation_period>\n+\n+Compute OHLCs for periods of the specified duration.\n+\n+=over 4\n+\n+=item *\n+\n+if period is less than a minute, then feed.tick table is used a the source\n+\n+=item *\n+\n+if period is from one minute and less than an hour, then feed.ohlc_minutely is\n+used as source. Using period that is not multiple of a minute is not wise as\n+returned data may not make much sense.\n+\n+=item *\n+\n+if period is one hour or more, but less than a day, then feed.ohlc_hourly is\n+used as source of data. Don't use intervals that not multiple of an hour.\n+\n+=item *\n+\n+if period is a day or more, then ohlc_daily is used as the source of data.\n+Don't use intervals that are not multiple of a day. If number of days is 7 then\n+I<end_time> will be aligned to the end of the week, and all intevals will start\n+at the start of the week (first interval may not actually start at the start of\n+the week, although timestamp in OHLC will indicate that it is). If number of\n+days is 30 then I<end_time> will be aligned to the end of the month and all\n+intervals will start at the start of the month (except maybe the first one).\n+\n+=back\n+\n+=back\n+\n+If interval is multiple of a day, than method will use official daily OHLC if\n+underlying has daily OHLC. It will never set I<official> property or returned\n+OHLC objects though.\n+\n+Method returns reference to a list of\n+L<Quant::Framework::Spot::OHLC>\n+\n+=cut\n+\n+sub ohlc_start_end {\n+    my $self = shift;\n+    my $args = shift;\n+\n+    my $start_time;\n+    my $end_time;\n+    $start_time = Date::Utility->new($args->{start_time})->datetime_yyyymmdd_hhmmss\n+        if ($args->{start_time});\n+    $end_time = Date::Utility->new($args->{end_time})->datetime_yyyymmdd_hhmmss\n+        if ($args->{end_time});\n+\n+    my $statement = $self->dbh->prepare_cached('SELECT * FROM ohlc_start_end($1, $2, $3, $4, $5)', {}, 3);\n+    $statement->bind_param(1, $self->underlying);\n+    $statement->bind_param(2, $args->{aggregation_period});\n+    $statement->bind_param(3, $start_time);\n+    $statement->bind_param(4, $end_time);\n+    $statement->bind_param(5, $self->use_official_ohlc ? 'TRUE' : 'FALSE');\n+\n+    return $self->_query_ohlc($statement);\n+}\n+\n+=head2 $self->ohlc_daily_list(\\%args)\n+\n+This method returns reference to list of daily OHLC for the specified period.\n+First and last OHLC maybe computed for the part of the day using ticks in\n+feed.tick table and not precomputed daily OHLC, so these two are non-official\n+OHLC. The rest of OHLCs may be official, but I<official> attribute won't be set\n+on them. Method accepts the following parameters:\n+\n+=over 4\n+\n+=item B<start_time>\n+\n+Compute OHLCs starting from the specified time\n+\n+=item B<end_time>\n+\n+Compute OHLCs till the specified moment of time\n+\n+=back\n+\n+Method returns reference to a list of L<Quant::Framework::Spot::OHLC> objects\n+\n+=cut\n+\n+sub ohlc_daily_list {\n+    my $self = shift;\n+    my $args = shift;\n+\n+    my $start_time;\n+    my $end_time;\n+    $start_time = Date::Utility->new($args->{start_time})->datetime_yyyymmdd_hhmmss\n+        if ($args->{start_time});\n+    $end_time = Date::Utility->new($args->{end_time})->datetime_yyyymmdd_hhmmss\n+        if ($args->{end_time});\n+\n+    my $statement = $self->dbh->prepare_cached('SELECT * FROM ohlc_daily_list($1, $2, $3, $4)', {}, 3);\n+    $statement->bind_param(1, $self->underlying);\n+    $statement->bind_param(2, $start_time);\n+    $statement->bind_param(3, $end_time);\n+    $statement->bind_param(4, $self->use_official_ohlc ? 'TRUE' : 'FALSE');\n+\n+    return $self->_query_ohlc($statement);\n+}\n+\n+=head2 combined_realtime_tick\n+\n+Returns combined tick for the given start/end time period.","path":"lib/Quant/Framework/Spot/DatabaseAPI.pm","position":null,"original_position":478,"commit_id":"0217cc6e29328f5c166a210c4931fb9f58a2f02e","original_commit_id":"5f4a4793a39dde47e153e2a0efb56d2e286dd86b","user":{"login":"mm-binary","id":9294049,"avatar_url":"https://avatars.githubusercontent.com/u/9294049?v=3","gravatar_id":"","url":"https://api.github.com/users/mm-binary","html_url":"https://github.com/mm-binary","followers_url":"https://api.github.com/users/mm-binary/followers","following_url":"https://api.github.com/users/mm-binary/following{/other_user}","gists_url":"https://api.github.com/users/mm-binary/gists{/gist_id}","starred_url":"https://api.github.com/users/mm-binary/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mm-binary/subscriptions","organizations_url":"https://api.github.com/users/mm-binary/orgs","repos_url":"https://api.github.com/users/mm-binary/repos","events_url":"https://api.github.com/users/mm-binary/events{/privacy}","received_events_url":"https://api.github.com/users/mm-binary/received_events","type":"User","site_admin":false},"body":"Seems this is not used anywhere. I removed the method","created_at":"2016-07-27T05:52:50Z","updated_at":"2016-07-27T05:52:50Z","html_url":"https://github.com/binary-com/perl-Quant-Framework/pull/50#discussion_r72384013","pull_request_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/50","_links":{"self":{"href":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/comments/72384013"},"html":{"href":"https://github.com/binary-com/perl-Quant-Framework/pull/50#discussion_r72384013"},"pull_request":{"href":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/50"}}},"pull_request":{"url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/50","id":77773103,"html_url":"https://github.com/binary-com/perl-Quant-Framework/pull/50","diff_url":"https://github.com/binary-com/perl-Quant-Framework/pull/50.diff","patch_url":"https://github.com/binary-com/perl-Quant-Framework/pull/50.patch","issue_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/issues/50","number":50,"state":"open","locked":false,"title":"initial files","user":{"login":"mm-binary","id":9294049,"avatar_url":"https://avatars.githubusercontent.com/u/9294049?v=3","gravatar_id":"","url":"https://api.github.com/users/mm-binary","html_url":"https://github.com/mm-binary","followers_url":"https://api.github.com/users/mm-binary/followers","following_url":"https://api.github.com/users/mm-binary/following{/other_user}","gists_url":"https://api.github.com/users/mm-binary/gists{/gist_id}","starred_url":"https://api.github.com/users/mm-binary/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mm-binary/subscriptions","organizations_url":"https://api.github.com/users/mm-binary/orgs","repos_url":"https://api.github.com/users/mm-binary/repos","events_url":"https://api.github.com/users/mm-binary/events{/privacy}","received_events_url":"https://api.github.com/users/mm-binary/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-07-18T08:25:41Z","updated_at":"2016-07-27T05:52:50Z","closed_at":null,"merged_at":null,"merge_commit_sha":"99180292061e36de7fdf5d79ea7ebd6d334e4861","assignee":{"login":"mm-binary","id":9294049,"avatar_url":"https://avatars.githubusercontent.com/u/9294049?v=3","gravatar_id":"","url":"https://api.github.com/users/mm-binary","html_url":"https://github.com/mm-binary","followers_url":"https://api.github.com/users/mm-binary/followers","following_url":"https://api.github.com/users/mm-binary/following{/other_user}","gists_url":"https://api.github.com/users/mm-binary/gists{/gist_id}","starred_url":"https://api.github.com/users/mm-binary/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mm-binary/subscriptions","organizations_url":"https://api.github.com/users/mm-binary/orgs","repos_url":"https://api.github.com/users/mm-binary/repos","events_url":"https://api.github.com/users/mm-binary/events{/privacy}","received_events_url":"https://api.github.com/users/mm-binary/received_events","type":"User","site_admin":false},"assignees":[{"login":"mm-binary","id":9294049,"avatar_url":"https://avatars.githubusercontent.com/u/9294049?v=3","gravatar_id":"","url":"https://api.github.com/users/mm-binary","html_url":"https://github.com/mm-binary","followers_url":"https://api.github.com/users/mm-binary/followers","following_url":"https://api.github.com/users/mm-binary/following{/other_user}","gists_url":"https://api.github.com/users/mm-binary/gists{/gist_id}","starred_url":"https://api.github.com/users/mm-binary/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mm-binary/subscriptions","organizations_url":"https://api.github.com/users/mm-binary/orgs","repos_url":"https://api.github.com/users/mm-binary/repos","events_url":"https://api.github.com/users/mm-binary/events{/privacy}","received_events_url":"https://api.github.com/users/mm-binary/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/50/commits","review_comments_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/50/comments","review_comment_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/comments{/number}","comments_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/issues/50/comments","statuses_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/statuses/0217cc6e29328f5c166a210c4931fb9f58a2f02e","head":{"label":"mm-binary:mm/spot_tick","ref":"mm/spot_tick","sha":"0217cc6e29328f5c166a210c4931fb9f58a2f02e","user":{"login":"mm-binary","id":9294049,"avatar_url":"https://avatars.githubusercontent.com/u/9294049?v=3","gravatar_id":"","url":"https://api.github.com/users/mm-binary","html_url":"https://github.com/mm-binary","followers_url":"https://api.github.com/users/mm-binary/followers","following_url":"https://api.github.com/users/mm-binary/following{/other_user}","gists_url":"https://api.github.com/users/mm-binary/gists{/gist_id}","starred_url":"https://api.github.com/users/mm-binary/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mm-binary/subscriptions","organizations_url":"https://api.github.com/users/mm-binary/orgs","repos_url":"https://api.github.com/users/mm-binary/repos","events_url":"https://api.github.com/users/mm-binary/events{/privacy}","received_events_url":"https://api.github.com/users/mm-binary/received_events","type":"User","site_admin":false},"repo":{"id":50819638,"name":"perl-Quant-Framework","full_name":"mm-binary/perl-Quant-Framework","owner":{"login":"mm-binary","id":9294049,"avatar_url":"https://avatars.githubusercontent.com/u/9294049?v=3","gravatar_id":"","url":"https://api.github.com/users/mm-binary","html_url":"https://github.com/mm-binary","followers_url":"https://api.github.com/users/mm-binary/followers","following_url":"https://api.github.com/users/mm-binary/following{/other_user}","gists_url":"https://api.github.com/users/mm-binary/gists{/gist_id}","starred_url":"https://api.github.com/users/mm-binary/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mm-binary/subscriptions","organizations_url":"https://api.github.com/users/mm-binary/orgs","repos_url":"https://api.github.com/users/mm-binary/repos","events_url":"https://api.github.com/users/mm-binary/events{/privacy}","received_events_url":"https://api.github.com/users/mm-binary/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mm-binary/perl-Quant-Framework","description":"A framework of objects upon which to build Financial Quantitative Analysis code","fork":true,"url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework","forks_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/forks","keys_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/teams","hooks_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/hooks","issue_events_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/issues/events{/number}","events_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/events","assignees_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/assignees{/user}","branches_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/branches{/branch}","tags_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/tags","blobs_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/git/refs{/sha}","trees_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/statuses/{sha}","languages_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/languages","stargazers_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/stargazers","contributors_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/contributors","subscribers_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/subscribers","subscription_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/subscription","commits_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/commits{/sha}","git_commits_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/git/commits{/sha}","comments_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/comments{/number}","issue_comment_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/issues/comments{/number}","contents_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/contents/{+path}","compare_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/merges","archive_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/downloads","issues_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/issues{/number}","pulls_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/pulls{/number}","milestones_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/milestones{/number}","notifications_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/labels{/name}","releases_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/releases{/id}","deployments_url":"https://api.github.com/repos/mm-binary/perl-Quant-Framework/deployments","created_at":"2016-02-01T06:36:04Z","updated_at":"2016-02-26T08:47:59Z","pushed_at":"2016-07-27T05:51:48Z","git_url":"git://github.com/mm-binary/perl-Quant-Framework.git","ssh_url":"git@github.com:mm-binary/perl-Quant-Framework.git","clone_url":"https://github.com/mm-binary/perl-Quant-Framework.git","svn_url":"https://github.com/mm-binary/perl-Quant-Framework","homepage":null,"size":597,"stargazers_count":0,"watchers_count":0,"language":"Perl","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":0,"forks":1,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"binary-com:master","ref":"master","sha":"099091603212d569370c4861da3091c42960519c","user":{"login":"binary-com","id":7437559,"avatar_url":"https://avatars.githubusercontent.com/u/7437559?v=3","gravatar_id":"","url":"https://api.github.com/users/binary-com","html_url":"https://github.com/binary-com","followers_url":"https://api.github.com/users/binary-com/followers","following_url":"https://api.github.com/users/binary-com/following{/other_user}","gists_url":"https://api.github.com/users/binary-com/gists{/gist_id}","starred_url":"https://api.github.com/users/binary-com/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/binary-com/subscriptions","organizations_url":"https://api.github.com/users/binary-com/orgs","repos_url":"https://api.github.com/users/binary-com/repos","events_url":"https://api.github.com/users/binary-com/events{/privacy}","received_events_url":"https://api.github.com/users/binary-com/received_events","type":"Organization","site_admin":false},"repo":{"id":50404733,"name":"perl-Quant-Framework","full_name":"binary-com/perl-Quant-Framework","owner":{"login":"binary-com","id":7437559,"avatar_url":"https://avatars.githubusercontent.com/u/7437559?v=3","gravatar_id":"","url":"https://api.github.com/users/binary-com","html_url":"https://github.com/binary-com","followers_url":"https://api.github.com/users/binary-com/followers","following_url":"https://api.github.com/users/binary-com/following{/other_user}","gists_url":"https://api.github.com/users/binary-com/gists{/gist_id}","starred_url":"https://api.github.com/users/binary-com/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/binary-com/subscriptions","organizations_url":"https://api.github.com/users/binary-com/orgs","repos_url":"https://api.github.com/users/binary-com/repos","events_url":"https://api.github.com/users/binary-com/events{/privacy}","received_events_url":"https://api.github.com/users/binary-com/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/binary-com/perl-Quant-Framework","description":"A framework of objects upon which to build Financial Quantitative Analysis code","fork":false,"url":"https://api.github.com/repos/binary-com/perl-Quant-Framework","forks_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/forks","keys_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/keys{/key_id}","collaborators_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/teams","hooks_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/hooks","issue_events_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/issues/events{/number}","events_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/events","assignees_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/assignees{/user}","branches_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/branches{/branch}","tags_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/tags","blobs_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/git/refs{/sha}","trees_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/git/trees{/sha}","statuses_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/statuses/{sha}","languages_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/languages","stargazers_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/stargazers","contributors_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/contributors","subscribers_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/subscribers","subscription_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/subscription","commits_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/commits{/sha}","git_commits_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/git/commits{/sha}","comments_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/comments{/number}","issue_comment_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/issues/comments{/number}","contents_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/contents/{+path}","compare_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/compare/{base}...{head}","merges_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/merges","archive_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/downloads","issues_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/issues{/number}","pulls_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls{/number}","milestones_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/milestones{/number}","notifications_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/labels{/name}","releases_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/releases{/id}","deployments_url":"https://api.github.com/repos/binary-com/perl-Quant-Framework/deployments","created_at":"2016-01-26T05:05:38Z","updated_at":"2016-06-13T17:26:41Z","pushed_at":"2016-07-27T05:51:49Z","git_url":"git://github.com/binary-com/perl-Quant-Framework.git","ssh_url":"git@github.com:binary-com/perl-Quant-Framework.git","clone_url":"https://github.com/binary-com/perl-Quant-Framework.git","svn_url":"https://github.com/binary-com/perl-Quant-Framework","homepage":null,"size":707,"stargazers_count":1,"watchers_count":1,"language":"Perl","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":10,"mirror_url":null,"open_issues_count":7,"forks":10,"open_issues":7,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/50"},"html":{"href":"https://github.com/binary-com/perl-Quant-Framework/pull/50"},"issue":{"href":"https://api.github.com/repos/binary-com/perl-Quant-Framework/issues/50"},"comments":{"href":"https://api.github.com/repos/binary-com/perl-Quant-Framework/issues/50/comments"},"review_comments":{"href":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/50/comments"},"review_comment":{"href":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/binary-com/perl-Quant-Framework/pulls/50/commits"},"statuses":{"href":"https://api.github.com/repos/binary-com/perl-Quant-Framework/statuses/0217cc6e29328f5c166a210c4931fb9f58a2f02e"}}}}
{"actor":{"display_login":"mm-binary"}}