Skip to content

24-7 Today

Menu
  • Home
  • Ads Guide
  • Blogging
  • Sec Tips
  • SEO Strategies
Menu

A Shiny app to visualize the Edgeworth box

Posted on August 23, 2025 by 24-7

[This article was first published on pacha.dev/blog, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)


Want to share your content on R-bloggers? click here if you have a blog, or here if you don’t.

Because of delays with my scholarship payment, if this post is useful to you I kindly ask a minimal donation on Buy Me a Coffee. It shall be used to continue my Open Source efforts. The full explanation is here: A Personal Message from an Open Source Contributor. If you play the electric guitar, the same scholarship chaos led me to turn my guitar pedals and DIY kits hobby into a business, and you can check those here.

I made a small Shiny app to visualize an Edgeworth box with contract curve for the 2×2 exchange model using Cobb-Douglas utility functions.

The idea is that the user can alter the parameters for the Cobb-Douglas functions to see how the contract curve changes and how much the market equilibrium (or Walras’ equilibrium) shifts from the initial allocation.

The initial endownments for good 1 and 2 and the normalized price can be changed as well.

Here is a preview:

To run the app locally, clone the repository https://github.com/pachadotdev/cobbdouglasge and then from RStudio/VSCode run the following in the R console:

devtools::load_all()
run_app()

The base for this demonstration was exercise 15.B.2 from MWG.

I hope this is useful!

Related

Related

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

©2025 24-7 Today | Design: WordPress | Design: Facts