Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pre registration fixes #1

Merged
merged 13 commits into from
May 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 9 additions & 10 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,28 +1,27 @@
name = "BeforeIT"
uuid = "ca9fcad7-41d0-4f76-b1e5-366c28bce52e"
authors = ["Aldo Glielmo <[email protected]>"]
authors = ["Aldo Glielmo <[email protected]>", "Mitja Devetak <[email protected]>"]
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"
57 changes: 52 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
<p align="center">
<img src="https://raw.githubusercontent.com/bancaditalia/BeforeIT.jl/main/docs/logo/logo_black_text.png" width="500">
<sup><a href="#footnote-1">*</a></sup>
</p>
<div align='center'>
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/bancaditalia/BeforeIT.jl/main/docs/logo/logo_white_text.png">
<source media="(prefers-color-scheme: light)" srcset="https://raw.githubusercontent.com/bancaditalia/BeforeIT.jl/main/docs/logo/logo_black_text.png">
<img alt="Logo adapts to light and dark modes" src="https://raw.githubusercontent.com/bancaditalia/BeforeIT.jl/main/docs/logo/logo_black_text.png" width="500">
</picture>
</div>

# Behavioural agent-based economic forecasting

Expand Down Expand Up @@ -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


<table>
<tr>
<td align="center">
<a href="https://github.com/AldoGl">
<img src="https://avatars.githubusercontent.com/AldoGl" width="100px;" alt="Aldo Glielmo"/><br />
<sub><b>Aldo Glielmo</b></sub>
</a><br />
<p>Banca d'Italia </p>
<p>Email: <a href="mailto:[email protected]:">[email protected]</a></p>
</td>
<td align="center">
<a href="https://devetak.github.io/">
<img src="https://avatars.githubusercontent.com/Devetak" width="100px;" alt="Mitja Devetak"/><br />
<sub><b>Mitja Devetak</b></sub>
</a><br />
<p>Paris 1: Pantheon - Sorbonne</p>
</td>
</tr>
</table>


## Disclaimer

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

<p id="footnote-1">
* Credits to <a href="https://www.bankit.art/people/sara-corbo">Sara Corbo</a> for the logo and to <a href="https://www.bankit.art/people/andrea-gentili">Andrea Gentili</a> for the name suggestion.
</p>
</p>
10 changes: 0 additions & 10 deletions docs/Project.toml

This file was deleted.

2 changes: 1 addition & 1 deletion examples/compare_model_vs_real.jl
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using BeforeIT
using MAT, FileIO, Plots, StatsPlots, Statistics
using MAT, FileIO, Plots, StatsPlots
using Dates

# load data from 1996
Expand Down
2 changes: 1 addition & 1 deletion examples/get_parameters_and_initial_conditions.jl
Original file line number Diff line number Diff line change
@@ -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
Expand Down
1 change: 0 additions & 1 deletion src/BeforeIT.jl
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
module BeforeIT

using Statistics
using Random
using StatsBase
import Base: round, length
Expand Down
2 changes: 1 addition & 1 deletion src/utils/estimate.jl
Original file line number Diff line number Diff line change
@@ -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)
Expand Down
2 changes: 1 addition & 1 deletion test/markets/test_search_and_matching_mod.jl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using BeforeIT, Test, MAT, Statistics
using BeforeIT, Test, MAT, StatsBase
using Random

Random.seed!(1)
Expand Down
2 changes: 1 addition & 1 deletion test/markets/test_search_and_matching_seed_stability.jl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using BeforeIT, Test, MAT, Statistics
using BeforeIT, Test, MAT, StatsBase
using Random

Random.seed!(1)
Expand Down
1 change: 0 additions & 1 deletion test/test_accounting_identities.jl
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
using BeforeIT, MAT, FileIO, Random
using Plots
using Test

dir = @__DIR__
Expand Down
2 changes: 1 addition & 1 deletion test/test_one_epoch.jl
Original file line number Diff line number Diff line change
Expand Up @@ -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__

Expand Down
2 changes: 1 addition & 1 deletion test/test_one_epoch_consistency.jl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using Revise
using BeforeIT
using MAT
using Test, Statistics
using Test

dir = @__DIR__

Expand Down
Loading