Creating an automated grocery list using SAS Enterprise Guide and prompts


Creating a grocery shopping list can be overwhelming for a variety of reasons. Lack of experience, picky eaters, and new recipes can turn an ambitious cook into an overwhelmed procrastinator. In this blog post I’ll show you an easy SAS Enterprise Guide project that uses prompts to create a simple user-interface for execution. The project allows you to select a subset of recipes from a long list in Excel, indicate the number of servings desired, and output a printable grocery list to take to the store. The key takeaways will be to demonstrate SAS Enterprise Guide prompts and provide a practical use for SAS in everyday life.

View this video for more details on the prompts and how the project was created.

Even when I am eager to cook, one place I might lose interest is when I have to figure out my shopping list from 5-7 different recipes. I LOVE MATH, but if I need 2 cups of shredded carrot for this and 2 carrot stalks for that, how many total carrots do I need? Sure, I can find the conversion formula with the help of the internet, but I’m likely to need to research it again the next time I reference the recipe.

I decided to make my own Excel workbook of recipes that my family enjoys and I’m constantly adding to it. Now, I make those conversions once and standardize the measures I use in my database. The initial data entry for six recipes took some time, figuring out what columns to use and entering the data, but now it takes me just a few minutes to add a recipe.


I used SAS Enterprise Guide to create an automated process for creating the shopping list and adjusting the recipe for the number of servings I want. Here is the high-level flow of the EG project.

  1. Import Excel Workbook
  2. Compute single serving amounts
  3. Prompt user to select the desired recipes from list and enter the required # of servings
  4. Recalculate ingredient amounts for chosen recipes with user-chosen # of servings
  5. Total ingredients across all chosen recipes
  6. Output shopping list
  7. Print and go to the store!


The Excel workbook and Enterprise Guide project are provided in this Enterprise Guide Community post.

In my next blog, I am going to revise this project and make it even better. I’ll definitely update my variable names and dataset names. What else would be a good next step?

  • Categorize recipes by paleo vs southern cooking vs low carb, etc. and include in prompts
  • Create the ability to use a different # of servings for each recipe
  • Add common unit of measure conversions and standardize
  • Improve the “look” of the final shopping list
  • Group the shopping list items by store section (produce, canned goods, butcher, etc.)
  • Other ideas?

I’d love to add your favorite recipes to the list as well. Please send them to

Please tell me what you think in the comments below, or find me on Twitter @Louanalytics.

Until next time.




About Author

Louanne Wright

Analytical Consultant

Louanne's dream finally came true in October 2014 when she started working at SAS Institute. Now she dreams of influencing young women across the world to marvel in the power of SAS. Louanne has over 10 years experience in the field of statistics leading teams and projects in the media industry. Louanne is a SAS Certified Advanced SAS Programmer with a Masters in Mathematical Sciences, Statistics Concentration from University of North Florida.

Leave A Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Back to Top