Coder Social home page Coder Social logo

Comments (2)

gdementen avatar gdementen commented on September 15, 2024
  1. you cannot currently do that: it loads all columns present in the input dataset if there are any rows for the current period in the input dataset. So you can have values for some periods but not others and some persons but not others but you need to have all input columns for each person that is present for a particular period. This is a stupid restriction but it is all due to the missing value problem (for int we cannot distinguish a value of -1 from a missing value/column for an individual, and it's even worse for booleans). When that problem will be fixed, extending the merge function (merge_arrays in data.py) to check for missing values should be relatively easy.

  2. yes, values loaded at the start of a period simply replace the value from the previous period, but are not treated differently during the simulation, so they are modified. If you want to keep the input value if present, you have to explicitly test it with something like (assuming a float column):

# column == column is meant to filter out nan (missing) values
column_in_input: column == column and column != lag(column)
column: if(column_in_input, column, expr_to_compute_column)

from liam2.

AlexisEidelman avatar AlexisEidelman commented on September 15, 2024

Thank you.

About the second point, I switched to an other tactics. I created an entity futur which looks like my entity person. With a link 'in_futur' from person to futur id i can write:

column: if(in_futur.id > -1, in_futur.column, expr_to_compute_column)

from liam2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.