Category: Computational Econ
-
Computing dynamic economic models in R for dummies: using deSolve to get qualitative solutions to Euler equations.
Note: A video explaining the content of this blog can be found here The computation of macroeconomic models is one which both fascinates and mystifies new students and scholars in this field. It certainly was a topic which seemed completely inaccessible to me without an advanced knowledge of algorithms and computational expertise. On an outset…
-
Computing A Simple Model of Competitive Equilibrium in R
In the previous posts we have learned how to compute a supply curve and a demand curve. What do we need to do to derive a competitive equilibrium? Before we answer that directly, lets first define what a competitive equilibrium is so to get everyone on the same page. Def: A Competitive Equilibrium CE={x,p} is…
-
Deriving the Supply Curve from the Profit Function in R
In this blog post we will discuss the derivation of a microfounded supply curve in R. Specifically we are interested in seeing how we can compute the supply curve from our firms objective problem. In this case we will consider solving for the supply curve from the following profit function: We note that in this…
-
Deriving the Demand Curve from the Consumer’s Objective Problem in R.
Note: This blog builds off of what was discussed previously here Continuing with our adventures with the NlcOptim package for R we start with trying to use it for deriving useful objects like the demand curve. Since we are economists we’re not going to simply define a downward sloping demand curve, rather we want to…
-
Utility Maximization in R using the “NlcOptim” package
In this blog post we will discuss how its possible to numerically solve utility maximization problems in R using the NlcOptim package. This package is particularly useful because it allows us to solve these problems with as few lines of code as possible. Lets get into it. A Consumer’s utility maximization problem is really just…