Skip to content

cumulative functions api design #25

@semio

Description

@semio

current format of accumulate:

procedure: accumulate
ingredients:
    - sg-datapoints
options:
    op:
        gdp: "aagr"  # run aagr() on gdp datapoints

but problem is:

  1. functions like aagr() can be run in multiple timeframes, e.g n years growth rate where n is parameter.
  2. we should only calculate these statistics within country, so we should always group them before accumulate.

To fix these problems we should add more options to the procedure, such as

procedure: accumulate
ingredients:
    - sg-datapoints
options:
    groupby:
        - geo
    op:
        gdp:
            func: aagr
            param:
                window: 10

EDIT: If we always need to groupby before accumulate. maybe combine accumulate procedure into groupby?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions