Skip to content

This repository contains the input data, R codes and results of the model developed in the paper "A dynamic fleet model of U.S light-duty vehicle lightweighting and associated greenhouse gas emissions from 2016-2050" published in Environmental Science and Technology (2019) by Alexandre Milovanoff, Hyung Chul Kim, Robert De Kleine, Timothy J. Wal…

amilovanoff/est_milovanoff_et_al_2019

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Repository Introduction

This repository contains the input data, R codes and results of the model developed in the paper "A dynamic fleet model of U.S light-duty vehicle lightweighting and associated greenhouse gas emissions from 2016-2050" published in Environmental Science and Technology (2019) by Alexandre Milovanoffa, Hyung Chul Kimb, Robert De Kleineb, Timothy J. Wallingtonb, I. Daniel Posena, Heather L. MacLeana,c.
a Department of Civil & Mineral Engineering, University of Toronto, 35 St. George Street, Toronto, Ontario, M5S 1A4 Canada
b Materials & Manufacturing R&A Department, Ford Motor Company, Dearborn, Michigan 48121-2053, United States
c Department of Chemical Engineering & Applied Chemistry, University of Toronto, 200 College Street, Toronto, Ontario, M5S 3E5 Canada

How to use this repository

This repository will not be updated but can be cloned and can serve new researches in the field. Feel free me to contact if you have any questions via email (alexandre.milovanoff@mail.utoronto.ca) or by GitHub @amilovanoff. There are two ways to use this repository:

How to set up the model the first time

  • Download the model from this repository on your local computer.
  • The model was developed using R and RStudio. Install RStudio. I use the RStudio Desktop Open Source License (free).
  • Once R and Rstudio are operationals, open the repository on your computer and open the file 'model_setup.RProj' in the main folder. It opens RStudio and sets up the working directory to the repository folder.
  • Open and run "architecture/library_dependencies.R". It installs all the packages used at some point in the model (i.e., in the functions or to create the plots). The model is operational.

How to run the model

  • To run the model once the model is set up, you simply have to open "model_setup.RProj" in the main folder. It opens RStudio and sets up the working directory.

If you want to extract the numerical values of the Supporting Information's figures

  • In reports, open "supporting_information.Rmd".
  • Make sure to run the first R chunk entitled "setup". This chunk defines some necessary elements to simulate the other chunks.
  • Simulate the chunk of interests by clicking on the play button at the right of the chunk. This simulates the code inside the chunk and creates the data frames and plots. If you have an error such as "cannot open the connection", try to simulate the "setup" chunk once again before resimulating the chunk of interests.

Repository description

The repository comprises 5 folders.

  • architecture: Contains some codes to create the model architecture. Compiles the list of inputs files, of interdependencies between the functions (i.e., how are the functions linked?) and define the set of attribute inputs to the functions.
  • functions: Contains the R scripts of the different functions of the model. Each function has a specific goal (e.g., compute the stock of light-duty vehicles by model year and vehicle type, or compute the flow of materials going in and ouf of the light-duty fleet stock). Outputs of a functions can be inputs of another function. The "architecture" folder contains the decription of the functions flow (i.e., interdependcies between functions).
  • inputs: Contains the external inputs of the functions and some R scripts to obtain formatted inputs data from raw inputs data.
  • outputs: Contains the intermediate or final outputs of the model functions. Most of the outputs are in .Rdata format and contains default results or results from simulations and sensitivity analysis. The folder also contains some plots.
  • reports: Contains some RMarkedown reports generated directly from the functions outputs. In this folder, the codes to generate the plots included in the paper are available as well as the full supporting information in RMarkedown format.

About

This repository contains the input data, R codes and results of the model developed in the paper "A dynamic fleet model of U.S light-duty vehicle lightweighting and associated greenhouse gas emissions from 2016-2050" published in Environmental Science and Technology (2019) by Alexandre Milovanoff, Hyung Chul Kim, Robert De Kleine, Timothy J. Wal…

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published