EIO-LCA Web Forum

A support and discussion resource for users of the website
It is currently Fri Dec 02, 2022 8:50 pm

All times are UTC - 5 hours

Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Wed Jun 23, 2010 10:20 pm 

Joined: Wed Jun 23, 2010 2:46 pm
Posts: 3
EIO-LCA 1997: ReadMe File for EIOLCA 1997 Model ZIP Archive

Disclaimer: This is the Matlab version of the 1997 EIO-LCA industry by industry model of the US economy. It is intended for users with an advanced understanding of Economic Input-Output Life Cycle Assessment and, like the web version of the model (at www.eiolca.net) it is provided as a service to the scientific community and is not supported. You will need to have Matlab, Microsoft Windows, and Microsoft Office installed on your computer to fully use this tool.

Please post any comments or questions about this model in the “1997 EIOLCA Matlab Model” thread.

Please note that Matlab, Microsoft Excel, and the online version of the model all manage significant digits differently. This may lead to the same value being displayed in multiple ways. For example 4095.263 may also appear as 4095.26 or 4100. While these values may appear different, given the way digits are managed (and the uncertainty of data in LCA models) they are the same values.

Files included in this ZIP archive:

CombinedVectors_12_06.xls: Environmental vectors used in current model. File used if user intends to input new environmental vectors into model or change certain values in vectors.
Eiind.xls: List of economic and environmental indicators by number (e.g., ‘Electricity, MkWh’ is the indicator, and 3 is found in the adjacent cell because it is the third indicator). Numbers shown are used for sorting vectors in Matlab model.
SectorNumbers.xls: List of economic sectors used in model, for industry-based producer price model and commodity-based retail price model. This is also the file into which model inputs are made: column C in each tab is the input vector to the model, in $1997 Million (see example below).
EIOLCAout.xls: Output file showing model results.
EIOLCA97.m: Matlab Model code
Reloaddata.m: subroutine to reload environmental vector.
eio97.mat: Matlab storage file which stores all matrices used in the model, including the current Economic matrices and environmental matrix. Variables contained in eio97.mat include:
- A – The 1997 industry by industry direct requirements matrix (also known as the A matrix)
- EIOsec –Input-Output sector codes
- EIOsecnames –Input-Output sector names
- EIvect – Matrix of energy and environmental impact vectors
- EnVectOrder – Vector storing the order of the environmental impacts as displayed in EIOLCAout.xls.
- Fen – Total Energy Vector
- Linv – Leontief inverse matrix
- W – Make Table - matrix mapping 491 industries into 483 commodities
- purchtransmat – matrix to split purchaser prices into producer price, wholesale margins, retail margins, and transportation margins (created using data from BEA)

Model Summary:

This is a standalone, Matlab version of the EIO-LCA web model with more flexibility and options than currently available on the web. It is actually two different models, both implemented from the same underlying code: a producer-price, industry-based model similar to the model published on the website, and a purchaser (retail) price, commodity-based model of similar form. The former model will replicate results shown on the web but allows inputs of compound vectors and changes to energy/environmental vectors easily. The latter is completely different and will only be able to be compared with web results in certain circumstances. It is designed to adjust for retail to producer prices, and thus model the delivery and retailing stages of the supply chain, as well as allowing modeling of commodities as opposed to industrial activity (e.g., a car instead of ‘automobile production’)

In order to simplify and streamline as much as possible, the code has been written as a script instead of a function, eliminating the need for inputs. Users input their preferences into the model inside Matlab through a text user interface. Similarly, for simplicity, all text file handling has been eliminated in favor of direct communication between Matlab and Excel. Thus, all input and output is handled through .xls file types. This functionality requires you to be running in Microsoft Windows (for Mac OS X users, this can be accomplished via Parallels, Boot Camp, etc.).

For a more in-depth understanding of how this model works, reading through the EIOLCA97.m code and all of its notes may be helpful.

Model Use:

Use of the model has been made as similar to the web model as possible. Inputs are made through Excel, in the file SectorNumbers.xls. This is similar to choosing a sector and increment of demand on the “use the model” web page at eiolca.net. This method allows for a bit more flexibility than the online model, as users can input demand into multiple sectors simultaneously. If the model is intended to be used in producer prices, input the value(s) for sectoral activity (in 1997 $M, producer prices) into the appropriate cell in column D adjacent to the modeled industry/industries in the first tab, ‘Industry (producer prices)’. For example, to model $1000 of non-federal electricity production, insert a 0.001 into cell D30, Power Generation and Supply. Similarly, if it is intended to use the commodity-based retail price model, insert a value for commodity retail price (in 1997 $M, retail prices) into column D in the second tab, ‘Commodity (retail prices)’. For example, to model the purchase of a car, insert 0.02 ($20,000) into cell D335 in the ‘Commodity’ tab.

The remaining activity takes place in Matlab. First make sure the current working directory in Matlab is the directory in which EIOLCA4.m resides. The present working directory is shown in the upper left window. Type ‘EIOLCA97’ into Matlab and hit enter. Several options are now given:
1. Select which model to use: 1 = producer price (industry basis), 2 = purchaser price (commodity basis)
2. Select indicator by which to sort the output sectors. The numbers are listed in the eiind.xls file. 1 = total economic activity through 32 = Total toxic releases and transfers.
3. Select how many sectors to output, from 1 to 491 for all sectors.
4. Select whether or not to reload environmental data. This will only need to be done if environmental vectors have been changed from the current ‘frozen’ vectors on the website (e.g., if you modified them manually in Matlab). 1 = reload data from CombinedVectors spreadsheet, 0 = use current data without reload.

At this point, the model will begin running and displays either the total production value for the producer price model, or the split between the production value, retail and wholesale markups, and transportation margins for delivery if the commodity retail model is chosen. All the rest of the work is done internally and the results are then written to EIOLCLAout.xls. Note that this file must be closed while the model runs or it will not be able to write. Open the file to view model results.

 Post subject:
PostPosted: Thu Jun 24, 2010 8:10 am 
Site Admin

Joined: Sat Aug 27, 2005 1:01 pm
Posts: 90
Here is the link for the 1997 Matlab model introduced above.


 Post subject:
PostPosted: Tue Jul 06, 2010 12:17 pm 
Site Admin

Joined: Sat Aug 27, 2005 1:01 pm
Posts: 90
Just a small note that I have re-posted the matlab zip file above for the 1997 model. There is only one change, for the benefit of users.

Derrick, who did the initial work to make the matlab zip file and wrote the readme file with it, noted that the two spreadsheets associated with the zip file - for input of a final demand and the outputs - already have values in them. Thus a user might not have noticed that there were already inputs and caused spurious results.

Thus these spreadsheets were "zeroed out" and reposted - nothing else has changed.

The URL is unchanged (just updated).

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC - 5 hours

Who is online

Users browsing this forum: No registered users and 1 guest

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group