#[macro_use]
extern crate agnes;
use agnes::source::csv::load_csv_from_uri;
tablespace![
table gdp {
CountryName: String,
CountryCode: String,
Gdp2015: f64,
}
];
fn main() {
let gdp_schema = schema![
fieldname gdp::CountryName = "Country Name";
fieldname gdp::CountryCode = "Country Code";
fieldname gdp::Gdp2015 = "2015";
];
let gdp_view = load_csv_from_uri("https://wee.codes/data/gdp.csv", gdp_schema)
.expect("CSV loading failed.");
println!("{}", gdp_view);
}