Beispiel #1
0
def test3():
    year = 2006
    erf = DataCollection(year=year)
    df = erf.get_of_values(table="eec_menage")
    from openfisca_core.simulations import SurveySimulation
    simulation = SurveySimulation()
    simulation.set_config(year=year)
    simulation.set_param()
    simulation.compute()  # TODO: this should not be mandatory
    check_consistency(simulation.input_table, df)
Beispiel #2
0
def test3():
    year=2006
    erf = DataCollection(year=year)
    df = erf.get_of_values(table = "eec_menage")
    from openfisca_core.simulations import SurveySimulation
    simulation = SurveySimulation()
    simulation.set_config(year=year)
    simulation.set_param()
    simulation.compute() # TODO: this should not be mandatory
    check_consistency(simulation.input_table, df)
Beispiel #3
0
def test():
    '''
    Validate check_consistency
    '''
    #===========================================================================
    # from pandas import DataFrame
    #res = DataFrame({af_col.name: simulation.output_table.get_value(af_col.name, af_col.entity)})
    # print res
    #===========================================================================

    store = HDFStore(os.path.join(os.path.dirname(os.path.join(SRC_PATH,'countries','france','data','erf')),'fichiertest.h5'))
    datatable = store.get('test12')
    test_simu = store.get('test_simu')
    print check_consistency(test_simu, datatable)
Beispiel #4
0
def test():
    '''
    Validate check_consistency
    '''
    #===========================================================================
    # from pandas import DataFrame
    #res = DataFrame({af_col.name: simulation.output_table.get_value(af_col.name, af_col.entity)})
    # print res
    #===========================================================================

    store = HDFStore(
        os.path.join(
            os.path.dirname(
                os.path.join(SRC_PATH, 'countries', 'france', 'data', 'erf')),
            'fichiertest.h5'))
    datatable = store.get('test12')
    test_simu = store.get('test_simu')
    print check_consistency(test_simu, datatable)