diff --git a/__pycache__/epidemic.cpython-36.pyc b/__pycache__/epidemic.cpython-36.pyc new file mode 100644 index 0000000000000000000000000000000000000000..940210b1657e0f30009e5417adde99c39471eb7f GIT binary patch literal 140 zcmXr!<>iWeUK7W_z`*brM8Gg30|SEt0|P@b3j+f~3PUi1CZpdjjXP!s3Nz`*dB0SPcMFfceUFfbJJFfcHrFr+ZHFhnt=Fa1wlv%9rl3JFU zlV6aVnpdKqoL`immsplrR9dW?o1c=JlbM&UUyxr=nv+ [-c ]') + sys.exit(2) + for opt, arg in opts: + if opt == '-h' or opt == '--help': + print('app.py -n [-c ]') + sys.exit(2) + elif opt == "-n": + n = arg + elif opt == "-c" or opt == '--config': + config_file = arg + if n == '': + print('app.py -n [-c ]') + sys.exit(2) + if config_file == '': + config_file = './data/census_data.json' + return n,config_file + +n = '' +config = '' +if __name__ == "__main__": + n, config = main(sys.argv[1:]) +else: + print("This file should not be imported. Please run from the command line.") + sys.exit(2) + +# n is set, config is set to name of census_data file +census_data = import_json(config) +population.generate(n, census_data) \ No newline at end of file diff --git a/data/census_data.json b/data/census_data.json index e69de29..2852b46 100644 --- a/data/census_data.json +++ b/data/census_data.json @@ -0,0 +1,6 @@ +{ + "age": { + "ages": [18,30,50,65], + "counts": [123,435,364,110,45] + } +} \ No newline at end of file diff --git a/epidemic_model.py b/epidemic.py similarity index 100% rename from epidemic_model.py rename to epidemic.py diff --git a/population.py b/population.py index e69de29..8063202 100644 --- a/population.py +++ b/population.py @@ -0,0 +1,3 @@ +def generate(n, config): + print("-- GENERATE POPULATION --") + print(config) \ No newline at end of file