diff --git a/Project.toml b/Project.toml index 2dd823f..f903ae9 100644 --- a/Project.toml +++ b/Project.toml @@ -1,28 +1,27 @@ name = "BeforeIT" uuid = "ca9fcad7-41d0-4f76-b1e5-366c28bce52e" -authors = ["Aldo Glielmo "] +authors = ["Aldo Glielmo ", "Mitja Devetak "] version = "0.1.0" [deps] -CSV = "336ed68f-0bac-5ca0-87d4-7b16caf5d00b" -DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0" Dates = "ade2ca70-3891-5945-98fb-dc099432e06a" -DelimitedFiles = "8bb1440f-4735-579b-a4ab-409b98df4dab" -DistributedArrays = "aaf54ef3-cdf8-58ed-94cc-d582ad619b94" Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f" FileIO = "5789e2e9-d7fb-5bc7-8068-2c6fae9b9549" -IJulia = "7073ff75-c697-5162-941a-fcdaad2a7d2a" JLD2 = "033835bb-8acc-5ee8-8aae-3f567f8a3819" JuliaFormatter = "98e50ef6-434e-11e9-1051-2b60c6c9e899" LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e" MAT = "23992714-dd62-5051-b70f-ba57cb901cac" NamedTupleTools = "d9ec5142-1e00-5aa0-9d6a-321866360f50" -Plots = "91a5bcdd-55d7-5caf-9e0b-520d859cae80" Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" -Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" StatsBase = "2913bbd2-ae8a-5f71-8c99-4fb6c76f3a91" -StatsPlots = "f3b207a7-027a-5e70-b257-86293d7955fd" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" [compat] -julia = "1.7.2" +Distributions = "0.25" +FileIO = "1.16" +JLD2 = "0.4" +JuliaFormatter = "1.0.56" +MAT = "0.10" +NamedTupleTools = "0.14" +StatsBase = "0.34" +julia = "1.9" diff --git a/README.md b/README.md index 9928ad0..80cf244 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,10 @@ -

- -* -

+
+ + + + Logo adapts to light and dark modes + +
# Behavioural agent-based economic forecasting @@ -75,6 +78,50 @@ say `main.jl`, and run it directly from the terminal by typing julia --project=. main.jl ``` + +## Download Source Code and Run Tests + +### Clone the Repository +```bash +git clone https://github.com/bancaditalia/BeforeIT.jl.git +cd BeforeIT.jl +``` + +### Activate and Instantiate the Environment +```bash +julia -e 'using Pkg; Pkg.activate("."); Pkg.instantiate();' +``` + +### Run Tests +```bash +julia --proj test/runtests.jl +``` + + +## Current Authors + + + + + + + +
+ + Aldo Glielmo
+ Aldo Glielmo +

+

Banca d'Italia

+

Email: aldo.glielmo@bancaditalia.it

+
+ + Mitja Devetak
+ Mitja Devetak +

+

Paris 1: Pantheon - Sorbonne

+
+ + ## Disclaimer This package is an outcome of a research project. All errors are those of @@ -84,4 +131,4 @@ the authors. All views expressed are personal views, not those of Bank of Italy.

* Credits to Sara Corbo for the logo and to Andrea Gentili for the name suggestion. -

\ No newline at end of file +

diff --git a/docs/Project.toml b/docs/Project.toml deleted file mode 100644 index db5e74a..0000000 --- a/docs/Project.toml +++ /dev/null @@ -1,10 +0,0 @@ -[deps] -Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f" -Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4" -FileIO = "5789e2e9-d7fb-5bc7-8068-2c6fae9b9549" -JLD2 = "033835bb-8acc-5ee8-8aae-3f567f8a3819" -Literate = "98b081ad-f1c9-55d3-8b20-4c87d4299306" -NamedTupleTools = "d9ec5142-1e00-5aa0-9d6a-321866360f50" -Plots = "91a5bcdd-55d7-5caf-9e0b-520d859cae80" -BeforeIT = "ca9fcad7-41d0-4f76-b1e5-366c28bce52e" -StatsBase = "2913bbd2-ae8a-5f71-8c99-4fb6c76f3a91" diff --git a/examples/compare_model_vs_real.jl b/examples/compare_model_vs_real.jl index 3242256..cd366ba 100644 --- a/examples/compare_model_vs_real.jl +++ b/examples/compare_model_vs_real.jl @@ -1,5 +1,5 @@ using BeforeIT -using MAT, FileIO, Plots, StatsPlots, Statistics +using MAT, FileIO, Plots, StatsPlots using Dates # load data from 1996 diff --git a/examples/get_parameters_and_initial_conditions.jl b/examples/get_parameters_and_initial_conditions.jl index 24e5552..75c20a8 100644 --- a/examples/get_parameters_and_initial_conditions.jl +++ b/examples/get_parameters_and_initial_conditions.jl @@ -1,7 +1,7 @@ # In this tutorial we illustrate how to calibrate the model to the Italian data for a specific quarter import BeforeIT as Bit -using Dates, Statistics, FileIO +using Dates, FileIO # We start from loading the calibration oject for italy, which contains 4 datasets: calibration_data, figaro, data, and ea diff --git a/src/BeforeIT.jl b/src/BeforeIT.jl index 909de20..a8346e3 100644 --- a/src/BeforeIT.jl +++ b/src/BeforeIT.jl @@ -1,6 +1,5 @@ module BeforeIT -using Statistics using Random using StatsBase import Base: round, length diff --git a/src/utils/estimate.jl b/src/utils/estimate.jl index 415143c..bbcbb49 100644 --- a/src/utils/estimate.jl +++ b/src/utils/estimate.jl @@ -1,4 +1,4 @@ -using LinearAlgebra, Random, Statistics, Distributions +using LinearAlgebra, Random, Distributions function estimate_next_value(data, type = nothing) alpha, beta, epsilon = estimate(data) diff --git a/test/markets/test_search_and_matching_mod.jl b/test/markets/test_search_and_matching_mod.jl index 31bd6e8..2d52a40 100644 --- a/test/markets/test_search_and_matching_mod.jl +++ b/test/markets/test_search_and_matching_mod.jl @@ -1,4 +1,4 @@ -using BeforeIT, Test, MAT, Statistics +using BeforeIT, Test, MAT, StatsBase using Random Random.seed!(1) diff --git a/test/markets/test_search_and_matching_seed_stability.jl b/test/markets/test_search_and_matching_seed_stability.jl index a945b86..ead71da 100644 --- a/test/markets/test_search_and_matching_seed_stability.jl +++ b/test/markets/test_search_and_matching_seed_stability.jl @@ -1,4 +1,4 @@ -using BeforeIT, Test, MAT, Statistics +using BeforeIT, Test, MAT, StatsBase using Random Random.seed!(1) diff --git a/test/test_accounting_identities.jl b/test/test_accounting_identities.jl index efc2f40..896230a 100644 --- a/test/test_accounting_identities.jl +++ b/test/test_accounting_identities.jl @@ -1,5 +1,4 @@ using BeforeIT, MAT, FileIO, Random -using Plots using Test dir = @__DIR__ diff --git a/test/test_one_epoch.jl b/test/test_one_epoch.jl index 4e8e8f9..40535f2 100644 --- a/test/test_one_epoch.jl +++ b/test/test_one_epoch.jl @@ -3,7 +3,7 @@ function randn(n1::Int, n2::Int) return ones(n1, n2) end -using BeforeIT, MAT, Test, Statistics +using BeforeIT, MAT, Test, StatsBase dir = @__DIR__ diff --git a/test/test_one_epoch_consistency.jl b/test/test_one_epoch_consistency.jl index 591bae1..7825b7a 100644 --- a/test/test_one_epoch_consistency.jl +++ b/test/test_one_epoch_consistency.jl @@ -1,7 +1,7 @@ using Revise using BeforeIT using MAT -using Test, Statistics +using Test dir = @__DIR__