Difference between revisions of "Example Models - Table"

Line 87: Line 87:
  
 
Requires Analytica Optimizer: The kernel fitting function (Kern_Fit) uses [[NlpDefine]].
 
Requires Analytica Optimizer: The kernel fitting function (Kern_Fit) uses [[NlpDefine]].
|
+
|cross-validation, overfitting, non-linear kernel functions
 
|[[Cross-Validation / Fitting Kernel Functions to Data]]
 
|[[Cross-Validation / Fitting Kernel Functions to Data]]
 
|-
 
|-
Line 93: Line 93:
 
|[[media:Bootstrapping.ana|Bootstrapping.ana]]
 
|[[media:Bootstrapping.ana|Bootstrapping.ana]]
 
|
 
|
|
+
|Bootstrapping is a technique from statistics for estimating the sampling error present in a statistical estimator.  The simplest version estimates sampling error by resampling the original data.  This model demonstrates how to do this in Analytica.
|
+
|bootstrapping, sampling error, re-sampling
 
|[[Statistical Bootstrapping]]
 
|[[Statistical Bootstrapping]]
 
|-
 
|-
Line 100: Line 100:
 
|[[media:Kernel_Density_Estimation.ana|Kernel Density Estimation.ana]]
 
|[[media:Kernel_Density_Estimation.ana|Kernel Density Estimation.ana]]
 
|
 
|
|
+
|This example demonstrates a very simple fixed-width kernel density estimator to estimate a "smooth" probability density.  The built-in PDF function in Analytica often has a choppy appearance due to the nature of histogramming -- it sets up a set of bins and counts how many points land in each bin.  A kernel density estimator smooths this out, producing a less choppy PDF plot.
|
+
 
 +
This smoothing is built into [[Analytica 4.4]].  You can select [[Kernel Density Smoothing|smoothing]] from the [[Uncertainty Setup dialog]].
 +
|kernel density estimation, kernel density smoothing
 
|[[Smooth PDF plots using Kernel Density Estimation]]
 
|[[Smooth PDF plots using Kernel Density Estimation]]
 
|-
 
|-
Line 107: Line 109:
 
|[[media:Output and input columns.ana|Output and input columns.ana]]
 
|[[media:Output and input columns.ana|Output and input columns.ana]]
 
|
 
|
|
+
|Presents an input table to a user, where one column is populated with computed output data, the other column with checkboxes for the user to select.  Although the '''Output Data''' column isn't read only, as would be desired, a [[Check Attribute]] has been configured to complain if he does try to change values in that column.  The model that uses these inputs would ignore any changes he makes to data in the '''Output Data''' column.
|
+
 
 +
Populating the '''Output Data''' column requires the user to press a button, which runs a button script to populate that column.  This button is presented on the top-level panel.  If you change the input value, the output data will change, and then the button needs to be pressed to refresh the output data column.
 +
|data analysis
 
|[[Output and Input Columns in Same Table]]
 
|[[Output and Input Columns in Same Table]]
 
|-
 
|-
  
 
|[[media:Platform 2018b.ana|Platform2018b.ana]]
 
|[[media:Platform 2018b.ana|Platform2018b.ana]]
|
+
|offshore platforms, oil and gas, stakeholders, rigs to reefs, decision support
|
+
|Too many environmental issues cause bitter public controversy. The question of how to decommission California's 27 offshore oil platforms started out as a typical example. But remarkably, after careful analysis a single option, "[http://lumina.com/case-studies/energy-and-power/a-win-win-solution-for-californias-offshore-oil-rigs rigs to reefs]", obtained the support of almost all stakeholders, including oil companies and environmentalists. A law to enable this option was passed by the California State house almost unanimously, and signed by Governor Arnold Schwarzenegger.
|
+
|decision analysis, multi-attribute, sensitivity analysis
 
|[[From Controversy to Consensus: California's offshore oil platforms]]
 
|[[From Controversy to Consensus: California's offshore oil platforms]]
 
|-
 
|-
  
 
|[[media:Comparing retirement account types.ana|Comparing retirement account types.ana]] or [[media:Comparing retirement account types without sensitivity.ana|Free 101 Compatible Version]]
 
|[[media:Comparing retirement account types.ana|Comparing retirement account types.ana]] or [[media:Comparing retirement account types without sensitivity.ana|Free 101 Compatible Version]]
|
+
|401(k), IRA, retirement account, decision analysis, uncertainty
|
+
|Will you end up with a bigger nest egg at retirement with a 401(k), traditional IRA, Roth IRA or a normal non-tax-advantaged brokerage account? For example, comparing a Roth IRA to a normal brokerage, intermediate capital gains compound in the Roth, but eventually you pay taxes on those gains at your income tax rate at retirement, whereas in the brokerage you pay capital gains taxes on the gains, which is likely a lower tax rate. So does the compounding outweigh the tax rate difference? What effect do the higher account maintenance fees in a 401(k) account have? How sensitive are these conclusions to the various input estimates? The answers to all these questions depend on your own situation, and may different for someone else. Explore these questions with this model.
|
+
|[[MultiTable]]s, sensitivity analysis
 
|[[Retirement plan type comparison]]
 
|[[Retirement plan type comparison]]
 
|-
 
|-
Line 128: Line 132:
 
|[[media:Plane catching with UI 2020.ANA|Plane catching with UI 2020.ANA]]
 
|[[media:Plane catching with UI 2020.ANA|Plane catching with UI 2020.ANA]]
 
|
 
|
|
+
|A simple decision analysis model of a familiar decision: What time I should leave my home to catch an early morning plane departure?  I am uncertain about the time to drive to the airport, walk from parking to gate (including security), and time needed at the departure gate. It also illustrates the Expected Value of Including Uncertainty (EVIU) -- the value of considering uncertainty explicitly in your decision making compared to ignoring it and assuming that all uncertain quantities are fixed at the median estimate.
|
+
 
 +
Details at [[Catching a plane example and EVIU]]. Includes downloadable model, slides, and video.
 +
|decision theory, decision analysis, uncertainty, Monte Carlo simulation, value of information, EVPI, EVIU
 
|[[Plane Catching Decision with Expected Value of Including Uncertainty]]
 
|[[Plane Catching Decision with Expected Value of Including Uncertainty]]
 
|-
 
|-
  
 
|[[media:Marginal Analysis for Control of SO2 Emissions.ana|Marginal Analysis for Control of SO2 Emissions.ana]]
 
|[[media:Marginal Analysis for Control of SO2 Emissions.ana|Marginal Analysis for Control of SO2 Emissions.ana]]
|
+
|environmental engineering
|
+
|Acid rain in eastern US and Canada caused by sulfur dioxide is emitted primarily by coal-burning electric-generating plants in the Midwestern U.S.  This model demonstrates a marginal analysis a.k.a. benefit/cost analysis to determine the policy alternative that leads us to the most economically efficient level of cleanup.
|
+
|cost-benefit analysis, marginal analysis
 
|[[Marginal Analysis for Control of SO2 emissions]]
 
|[[Marginal Analysis for Control of SO2 emissions]]
 
|-
 
|-
Line 142: Line 148:
 
|[[Media:Donor_Presenter_Dashboard_II.ANA|Donor-Presenter Dashboard.ana]]
 
|[[Media:Donor_Presenter_Dashboard_II.ANA|Donor-Presenter Dashboard.ana]]
 
|
 
|
|
+
|This model implements a continuous-time Markov chain in Analytica's discrete-time dynamic simulation environment.  It supports immigration to, and emigration from, every node.
|
+
 
 +
It can be used by an arts organization to probabilistically forecast future audience evolution, in both the short and the long (steady state) term.  It also allows for uncertainty in the input parameters.
 +
|dynamic models, Markov processes
 
|[[Donor/Presenter Dashboard]]
 
|[[Donor/Presenter Dashboard]]
 
|-
 
|-

Revision as of 00:04, 22 November 2022


This page lists example models and libraries. You can download them from here or (in some cases) link to a page with more details. Feel free to include and upload your own models and libraries.

Download Model Domain Description Methods For more
Marginal abatement home heating.ana carbon price, energy efficiency, climate policy This model, along with the accompanying blog article, show how to set up a Marginal Abatement graph in Analytica. graph methods, optimal allocation, budget constraint Marginal Abatement Graph
Solar Panel Analysis.ana renewable energy, photovoltaics, tax credits Would it be cost effective to install solar panels on the roof of my house? This model explores this question for my situation in San Jose, California. An accompanying video documents the building of this model, and is a good example of the process one goes through when building any decision model.

The model explores how many panels I should install, and what the payoff is in terms of net present value, Internal rate of return and time to recoup cost. It also looks at whether I should postpone the start of the installation to take advantage of rapidly falling PV prices, or cash in on tax credits.

net present value, internal rate of return, agile modeling Solar Panel Analysis
Items within budget.ana Given a set of items, with a priority and a cost for each, the function Items_within_budget function selects out the highest priority items that fit within the fixed budget. Items within Budget function
Grant exclusion.ana business analysis This model tests a hypothesis about the distribution of an attribute of the marginal rejectee of a grant program, given the relevance of that attribute to award of the grant. It could be used by an organization to make decisions as to whether to fiscally-sponsor another organization that will use that fiscal sponsorship to apply for grants, by looking at the effect on the pool of grant recipients overall. Grant Exclusion Model
Project Priorities 5 0.ana business models This is a demo model that shows how to:
  • Evaluate a set of R&D projects, including uncertain R&D costs, and uncertain revenues if it leads to release of a commercial product.
  • Use multiattribute analysis to compare projects, including a hard attribute -- expected net present value -- and soft attributes -- strategic fit, staff development, and public good will.
  • Compare cost, NPV, and multiattribute value for a selected portfolio of projects.
  • Generate the best portfolio (ratio of NPV or multiattribute merit to cost) given a R&D budget.
cost analysis, net present value (NPV), uncertainty analysis Project Planner
Steel and aluminum tariff model.ana On 2-March-2018, President Trump proposed new import tariffs on steel and aluminum. It seems as if the projected net impacts of these tariffs on the total US trade deficit and US economy depends largely on which news outlets you get your news from. We thought it would be helpful to put together a simple and easy to understand model to estimate of the net impact of these tariffs on the US trade deficit, assuming that no other factors change (e.g., no retaliatory tariffs are enacted by other countries). We wanted something that allows you to understand how its estimates are being derived, with assumptions that can be easily replaced with your own, so that the model itself would be impartial to any particular viewpoint. We want the uncertainties that are inherent in such a simple model to be explicit, so you can see the range of possibilities and not just a single guess. Finally, we wanted the model to be easy to understand fully for non-economists (a group to which we belong, too).

This model accompanied a current event blog post on the Lumina blog: Impact of Trump’s proposed Steel & Aluminum tariffs on US trade deficit

Steel and Aluminum import tariff impact on US trade deficit
Tax bracket interpolation 2021.ana Computes amount of tax due from taxable income for a 2017 US Federal tax return. To match the IRS's numbers exactly, it is necessary to process tax brackets correctly as well as implementation a complex mix of rounding rules that reproduce the 12 pages of table lookups from the Form 1040 instructions. This model is showcased in a blog article, How to simplify the IRS Tax Tables. Tax bracket interpolation
Feasible Sampler.ana feasibility You have a bunch of chance variables, each with a probability distribution. Their joint sample, however, contains some combinations of points that are (for one reason or another) physically impossible. We'll call those infeasible points. You'd like to eliminate those points from the sample and keep only the feasible points.

This module implements a button that will sample a collection of chance variables, then reset the sample size and keep only those sample points that are "feasible".

Obviously, this approach will work best when most of your samples are feasible. If you can handle the "infeasible" points in your model directly, by conditioning certain chance variables on others, that is far preferable. But there are some cases where this solution (although a bit of a kludge) is more convenient.

The instructions for how to use this are in the module description field.

statistics, sampling, importance sampling, Monte Carlo simulation Sampling from only feasible points
Cross-validation example.ana When fitting a function to data, if you have too many free parameters relative to the number of points in your data set, you may "overfit" the data. When this happens, the fit to your training data may be very good, but the fit to new data points (beyond those used for training) may be very poor.

Cross-validation is a common technique to deal with this problem: We set aside a fraction of the available data as a cross-validation set. Then we begin by fitting very simple functions to the data (with few free parameters), successively increasing the number of free parameters, and seeing how the predictive performance changes on the cross-validation set. It is typical to see improvement on the cross-validation set for a while, followed by a deterioration of predictive performance on the cross-validation set once overfitting starts occurring.

This example model successively fits a non-linear kernel function to the residual error, and uses cross-validation to determine how many kernel functions should be used.

Requires Analytica Optimizer: The kernel fitting function (Kern_Fit) uses NlpDefine.

cross-validation, overfitting, non-linear kernel functions Cross-Validation / Fitting Kernel Functions to Data
Bootstrapping.ana Bootstrapping is a technique from statistics for estimating the sampling error present in a statistical estimator. The simplest version estimates sampling error by resampling the original data. This model demonstrates how to do this in Analytica. bootstrapping, sampling error, re-sampling Statistical Bootstrapping
Kernel Density Estimation.ana This example demonstrates a very simple fixed-width kernel density estimator to estimate a "smooth" probability density. The built-in PDF function in Analytica often has a choppy appearance due to the nature of histogramming -- it sets up a set of bins and counts how many points land in each bin. A kernel density estimator smooths this out, producing a less choppy PDF plot.

This smoothing is built into Analytica 4.4. You can select smoothing from the Uncertainty Setup dialog.

kernel density estimation, kernel density smoothing Smooth PDF plots using Kernel Density Estimation
Output and input columns.ana Presents an input table to a user, where one column is populated with computed output data, the other column with checkboxes for the user to select. Although the Output Data column isn't read only, as would be desired, a Check Attribute has been configured to complain if he does try to change values in that column. The model that uses these inputs would ignore any changes he makes to data in the Output Data column.

Populating the Output Data column requires the user to press a button, which runs a button script to populate that column. This button is presented on the top-level panel. If you change the input value, the output data will change, and then the button needs to be pressed to refresh the output data column.

data analysis Output and Input Columns in Same Table
Platform2018b.ana offshore platforms, oil and gas, stakeholders, rigs to reefs, decision support Too many environmental issues cause bitter public controversy. The question of how to decommission California's 27 offshore oil platforms started out as a typical example. But remarkably, after careful analysis a single option, "rigs to reefs", obtained the support of almost all stakeholders, including oil companies and environmentalists. A law to enable this option was passed by the California State house almost unanimously, and signed by Governor Arnold Schwarzenegger. decision analysis, multi-attribute, sensitivity analysis From Controversy to Consensus: California's offshore oil platforms
Comparing retirement account types.ana or Free 101 Compatible Version 401(k), IRA, retirement account, decision analysis, uncertainty Will you end up with a bigger nest egg at retirement with a 401(k), traditional IRA, Roth IRA or a normal non-tax-advantaged brokerage account? For example, comparing a Roth IRA to a normal brokerage, intermediate capital gains compound in the Roth, but eventually you pay taxes on those gains at your income tax rate at retirement, whereas in the brokerage you pay capital gains taxes on the gains, which is likely a lower tax rate. So does the compounding outweigh the tax rate difference? What effect do the higher account maintenance fees in a 401(k) account have? How sensitive are these conclusions to the various input estimates? The answers to all these questions depend on your own situation, and may different for someone else. Explore these questions with this model. MultiTables, sensitivity analysis Retirement plan type comparison
Plane catching with UI 2020.ANA A simple decision analysis model of a familiar decision: What time I should leave my home to catch an early morning plane departure? I am uncertain about the time to drive to the airport, walk from parking to gate (including security), and time needed at the departure gate. It also illustrates the Expected Value of Including Uncertainty (EVIU) -- the value of considering uncertainty explicitly in your decision making compared to ignoring it and assuming that all uncertain quantities are fixed at the median estimate.

Details at Catching a plane example and EVIU. Includes downloadable model, slides, and video.

decision theory, decision analysis, uncertainty, Monte Carlo simulation, value of information, EVPI, EVIU Plane Catching Decision with Expected Value of Including Uncertainty
Marginal Analysis for Control of SO2 Emissions.ana environmental engineering Acid rain in eastern US and Canada caused by sulfur dioxide is emitted primarily by coal-burning electric-generating plants in the Midwestern U.S. This model demonstrates a marginal analysis a.k.a. benefit/cost analysis to determine the policy alternative that leads us to the most economically efficient level of cleanup. cost-benefit analysis, marginal analysis Marginal Analysis for Control of SO2 emissions
Donor-Presenter Dashboard.ana This model implements a continuous-time Markov chain in Analytica's discrete-time dynamic simulation environment. It supports immigration to, and emigration from, every node.

It can be used by an arts organization to probabilistically forecast future audience evolution, in both the short and the long (steady state) term. It also allows for uncertainty in the input parameters.

dynamic models, Markov processes Donor/Presenter Dashboard
Photosynthesis Regulation.ana - main regulation pathways
Photosystem.ana - rough sketch of genetic regulation
Regulation of Photosynthesis
Time-series-reindexing.ana Time-series re-indexing
Post Compression Model Timber Post Compression Load Capacity
Compression Post Load Capacity.ana Compression Post Load Calculator
Daylighting analyzer.ana Daylighting Options in Building Design
California Power Plants.ana California Power Plants
Electrical Transmission.ana Electrical Generation and Transmission
Time of use pricing.ana & MECOLS0620.xlsx
(both files needed)
Time of Use pricing
Color map.ana Color Map
World cup.ana 2018 World Cup Soccer final
resnet18.zip Image recognition
Month to quarter.ana Transforming Dimensions by transform matrix, month to quarter
Convolution.ana Convolution
Dependency Tracker.ana Dependency Tracker Module
French-English.ana Multi-lingual Influence Diagram
Parsing XML example.ana Extracting Data from an XML file
Vector Math.ana Vector Math
Total Allowable w Optimizer.ana or
Total Allowable w StepInterp.ana for those without Optimizer
Total Allowable Harvest
Cereal Formulation1.ana Linearizing a discrete NSP
Neural Network.ana Neural Network
Earthquake expenses.ana Earthquake Expenses
Loan policy selection.ana Loan Policy Selection
Hubbard_and_Seiersen_cyberrisk.ana Inherent and Residual Risk Simulation
media:Red State Blue State plot.ana Red or blue state
COVID Model 2020--03-25.ana COVID-19 State Simulator, a Systems Dynamics approach
Corona Markov.ana How social isolation impacts COVID-19 spread in the US - A Markov model approach
Modelo Epidemiológoco para el Covid-19 con cuarentena.ana Epidemiological model of COVID-19 for Perú, en español
COVID-19 Triangle Suppression.ana A Triangle Suppression model of COVID-19
Simple COVID-19.ana COVID-19 Coronavirus SICR progression for 2020
US COVID-19 Data.ana COVID-19 Case and Death data for US states and counties
Voluntary vs mandatory testing.ana Mandatory vs Voluntary testing policies
Comments


You are not allowed to post comments.