Thursday, November 08, 2018

R Packages: leonRdo & inteRest

I have recently developed two packages that can accompany the modeling simulation platform I described in my book Business Case Analysis with R: Simulation Tutorials to Support Complex Business Decisions (available at Springer-Nature/Apress and Amazon).

These packages are:

  • leonRdo 0.1.4: provides median Latin hypercube sampling
  • inteRest 1.0: provides basic finance functions
Go here to see how you can install these packages and see a few highlights from their contents.

Friday, August 03, 2018

Bayesian Reasoning: Discrete Inference with Sequential Data

Or, One Way I Learned to Quit Believing My Prejudices

In my last article on this topic, I showed that considering background information can play a significant role in helping us make less biased judgments. What I hope to show now is that while we learn by updating the information we have through experience, limited experiences can often lead to prejudices about the way we interpret the world; but even broad and deep experience should rarely lead us to certain conclusions.

To get started, imagine playing a game in which someone asks you to infer the number of sides of a die based on the face numbers that show up in repeated throws of the die. The only information you are given beforehand is that the actual die will be selected from a set of seven die having these number of faces: (4, 6, 8, 10, 12, 15, 18). Assuming you can trust the person who reports the outcome on each throw, after how many rolls of the die will you be willing to specify which die was chosen?

Let's use the R programming language to help us think through the problem. Start by specifying the set of the die possibilities such that each number represents the number of sides of a given die. (You might also want to refer to my previous article on Bayesian analysis to familiarize yourself with some of the terminology that follows.)

To read the entire discussion go here.

Friday, March 09, 2018

Book Release: Business Case Analysis with R

I am happy to announce that "Business Case Analysis with R" has been republished through Springer-Nature/Apress. The title is available at both Springer-Nature/Apress and Amazon.

"This tutorial teaches you how to use the statistical programming language R to develop a business case simulation and analysis. It presents a methodology for conducting business case analysis that minimizes decision delay by focusing stakeholders on what matters most and suggests pathways for minimizing the risk in strategic and capital allocation decisions. Business case analysis, often conducted in spreadsheets, exposes decision makers to additional risks that arise just from the use of the spreadsheet environment."



Contact us if you would like to receive a copy for journalistic or academic review or purchase books in bulk for your organization.

So far, the reviews on Amazon have been great!

★★★★★ This book is a great resource for anyone looking to learn more about running simulations
By Matthew C Marzillo on March 30, 2018
I came across this book while I was looking to find a practical resource for applying simulation methods in business settings. While there are many resources on simulation models for academic and research applications there aren't many that address simulations from a business stand point. This book is a great resource for anyone looking to learn more about running simulations and getting some real world experience by test driving Robert's R code. A technical book that is easy read...for the price, it's really hard to pass up!

★★★★★ This book has made me a better analyst
By Buffalo Gal on March 27, 2018
Last week I bought this because I have a project merging 85 spreadsheets with R. I am still on chapter 2 but I LOVE THIS BOOK. Let me tell you why.
A. Intuitive Organization. The book begins with a discussion of what motivated the author - to facilitate more accurate, clear and practical analysis by using R instead of complex spreadsheet designs. It discusses guidelines like file architecture and R syntax. It lays out a progressive approach to the Business Case analysis, starting with the basics.
B. Incredible Content. The elegant code is written in base R so it avoids the drama that can come from snazzy packages. It does require some confidence with R. At the same time it inspires me to stretch my skills and try more sophisticated techniques like Monte Carlo and stochastic simulations
C. Solid delivery. It is easy-to-read even though it is chock full of technical details. It does not have fancy color pictures but it does have simple graphs and visuals that are helpful and easy to understand.

I can't wait to read the rest of this book. It is filled with treasures that will make me more productive, thorough and effective.


★★★★★ Works for any sector and organization
By Russell J Moore on March 25, 2018
I run a niche consulting business focused on education reform. Public education has a long tradition of poor decision-making driven by powers-that-be protectors of the status quo. I am using R - and specifically the tutorials in this book - to identify existing and new measures to include in goals and strategic plans that will actually “move the needle” in public and private K-12 and higher education. I have also shown my copy to friends who do similar critical decision-making in large, private healthcare organizations and have used R before. Just a short skim through this book got them excited about “going deeper” and rejuvenating their analyses and processes. I predict this useful “how to” will take many industries by storm.

★★★★★ R finally enters in the Strategic Planning field.
By Carlos Ortega Fernandez on March 23, 2018
I knew this book through the same author in LinkedIn and I could not withstand to buy it immediately, it deserved it. The subject is not easy, Strategic Planning combines financial concepts but more and more if you want to explore alternative scenarios is when you will require mathematics and probability. This is what this good book is about.

The novel approach it offers is that is written in a very easy to follow R programming language. Perhaps it is the only book about this subject and entirely written in R.

Hopefully there will be new extensions of the book that take advantage of the extensive R's optimization libraries as well as its graphical capabilities.


★★★★★ A very accessible introduction to modelling business scenarios.
By Bill Neaves on March 22, 2018 (on the Canadian Amazon site)
A great overview on business analysis and modelling as a discipline. It is a good addition to my my library on using R as an alternative to spreadsheets. Well done.

★★★★★ A great start on modeling complex business systems
By JAD_ClimBiz on March 20, 2018
I had the good fortune to find Business Case Analysis with R, by Robert D. Brown III, when I was looking for examples of business simulation software. It turned out to be just what I need to get started.

The influence diagrams are especially useful in showing how many factors interact to shape the evolution of a complex business system, especially with and without the many possibilities for uncertainty that must be treated probabilistically.

With the guidance provided by the book, I was able to develop a very useful model of climate change impacts on an electric utility, including probabilistic demand and production of hydro and solar power. The numerical estimates were combined with judgments related to subjective criteria including profitability, reliability, and responsibility using the analytical hierarchy process to suggest an optimum generation asset configuration for the 21st century.


★★★★★ Build better models
By Salil A. Athalye on March 17, 2018
I am one of the fortunate people who made a connection with Robert Brown by purchasing his LeanPub publication entitled Business Case Analysis with R – A Simulation Tutorial to Support Complex Business Decisions. The book comes in at under 100 pages, and the price is less than a week’s worth of Espresso shots, but the value is incalculable.

The general received wisdom for most laypeople in this field is: 1) pick a tool 2) develop a spreadsheet 3) pick one or more distributions based on the similarity to the shape of the distribution and your data and then 4) go wild. Robert, on the other hand, takes great pains to present an effective thought process and workflow and gently guides the reader to help them implement a working example model. At the same time he is imparting wisdom from deep expertise in this field and uncovering some of the theoretical underpinnings that informs model builders in the art and practice without drawing out the heavy duty statistics and mathematics. There are some hidden gems in the R code and some more in the margins. There is an underlying sense of humor and passion for sharing this knowledge evident in the writing.

I am familiar with R but still learned many new tips and tricks. The use of functional programming constructs such as sapply took a while to get used to and in many cases I chose to use loops to help myself while I learned the material. Coming from a 2D spreadsheet world you have to be able to think in terms of data structures and data flows and transformations. Kind of like relearning linear algebra. My tip is to use str() with some of his data structures so you can understand how the indices are traversing through the data structures and how the code is transforming the structures. I must say it does make you appreciate what Excel is doing underneath the hood!

Using this book, I was able to design and implement a full business case simulation for our organization that incorporates uncertainty and risk. This helps us move from single point estimates to ranges and embody uncertainty and risk. And in short order I made it my own by incorporating reproducible research elements using knitr and I have plans to implement a front-end using Shiny. You can spend hundreds of dollars buying college textbooks on this subject matter but many of these books don’t help you actually start implementing a system and using it. That’s why this book is a hidden gem.

And so, why do I feel fortunate? Well, in asking Robert a few questions related to the material I received not only the answers, but also encouragement, perspective and expertise. The combination of all this goodwill flowing back feels like mentoring and I’m very grateful for Robert’s time.

So thank you Robert, for sharing your expertise and wisdom in this book. I highly recommend it to anyone who is not a full time Decision Professional and yet needs to understand the underpinnings of the field and who is ready to move away from Excel spreadsheet hell and leverage the power and flexibility of R.

I look forward to buying new publications from Robert Brown and highly encourage you to buy this book.


★★★★★ Concise tutorials on decision analysis using R language
By AndrewG on March 17, 2018
This book is a re-edited collection of four books originally self-published book on leanpub.com. The book contains four main sections, 1) Business Case Analysis with R, using R programming language to simulate four complex business decisions 2) It's Your Move, about tackling valuable strategic decisions 3) Subject Matter Expert Elicitation Guide, to help assess uncertainties when little data is available, and 4) Information Expresso, about using the value of information (VOI) to make clear decisions efficiently. There also five appendicies: A) Deterministic Model, B) Risk Model, C) Simulation and Finance Functions, D) Decision Hierarchy and Strategy Tables, E) VOI Code Samples. These are a collection of R code and Excel templates explained in the body of the text.

In 2017, I had purchased the self-published ebook mainly looking for R code for concrete examples of Decision Analysis in business. I had purchased previous similarly titled books for Excel, but found them lacking in depth. The author takes an imaginary business, describes the inter-related concerns of revenue and costs to calculate a range of net present values. Then the authors adds additional assumptions and code to model risks, showing the effect on the previous model. It is instructive to see the effect of assumptions on changes on a case by case basis. What the mind has a hard time visualizing, the graphic outputs clearly point out. Of course, the R code can be modified to model other businesses.

I anxiously awaited the release of this book and pdf edition, I am quite pleased with the final product. I found the author's examples and explanations appropriate and clear. The R code, available on the books website, ran in RStudio without difficulty, producing outputs and plots exactly as published.

If your looking for a single source book for concepts and R code on applying Decision Analysis on more complicated, interconnected decisions, I highly recommend this book. The content the first section alone, justifies the price of the entire book. The R code is commented well enough that a programmer could easily translate the algorithms to other programming languages.

Friday, August 04, 2017

Bayesian Reasoning: Gender Inference from a Specimen Measurement

Imagine that we have a population of something composed of two subset populations that, while distinct from each other, share a common characteristic that can be measured along some kind of scale. Furthermore, let’s assume that each subset population expresses this characteristic with a frequency distribution unique to each. In other words, along the scale of measurement for the characteristic, each subset displays varying levels of the characteristic among its members. Now, we choose a specimen from the larger population in an unbiased manner and measure this characteristic for this specific individual. Are we justified in inferring the subset membership of the specimen based on this measurement alone? Baye’s rule (or theorem), something you may have heard about in this age of exploding data analytics, tells us that we can be so justified as long as we assign a probability (or degree of belief) to our inference. The following discussion provides an interesting way of understanding the process to do this. More importantly, I present how Baye’s theorem helps us overcome a common thinking failure associated with making inferences from an incomplete treatment of all the information we should use. I’ll use a bit of a fanciful example to convey this understanding along with showing the associated calculations in the R programming language.

Suppose we are aliens from another planet conducting scientific research on this strange group of bipedal organisms called humans...



To read the entire discussion go here.

Saturday, July 22, 2017

VoyageATL is an online magazine that highlights local small businesses and entrepreneurs and promotes local events. A few days ago they published a small piece on my company, Incite.

Read more VoyageATL - Incite! Decision Technologies.

Book trailers

I made the following "movie" trailers for two of my tutorials to play with the idea of making a teaser that didn't attempt to explain anything, but mostly just to have some fun.

It’s Your Move: Creating Valuable Decision Options When You Don’t Know What to Do


Information Espresso: Using Value of Information for Making Clear Decisions (with support from the R programming language)

Monday, November 14, 2016

Seeking Beta Testers for a Web-based Sales Opportunity Portfolio Analysis Tool



Incite! Decision Technologies has recently developed a simple yet sophisticated web-based sales opportunity portfolio analysis tool that is ready for beta testing. Now we're seeking parties that would be interested in participating at no cost and no obligation.

Specifically, we are looking for progressive sales managers in firms whose sales team pursues high value, low-frequency sales. Examples of target firms might be...
  • Engineering, architecture & construction firms
  • Professional service firms
  • Capital equipment manufacturers
  • Start-ups
The purpose of the tool is to provide
  • Improved accuracy of revenue realization and timing forecasts;
  • Guidance on how to allocate resources to maximize the likelihood of deal closure;
  • Guidance on opportunity selection and prioritization.
Ultimately, you will be able to determine if the sales opportunities you are pursuing are worth the time, effort, and resources.

If you are interested in learning more or know someone who might be, please, contact me via LinkedIn message or send me an email from our web form.

Wednesday, November 09, 2016

The Power of Negative Thinking: “How do we know this opportunity is worth the time and effort?”

The sales process is an inherently risky business. It’s difficult to know if and when a deal will close, what clients really want regardless of what they have stated (i.e., the client may have failed to frame their own needs properly), and what competitors offer in price and quality of deliverables.

Compounding the external uncertainty, we often get in our own way by importing certain kinds of biases into our assessment of the value of the sales opportunities at hand. These biases can include…
  • Unwarranted optimism or wishful thinking – personal enthusiasm or a natural disposition to believe that desired outcomes will most likely occur; or, inflating initial estimates of desired outcomes to appear more effective than is warranted;
  • Sand-bagging – under reporting potential outcomes to appear heroic when better than anticipated outcomes materialize;
  • False precision – reporting anticipated outcomes with an unjustified level of certainty, usually as a single-point estimate rather than a range;
  • Availability – recalling values that are memorable, easily accessible, recent, or extreme;
  • Anchoring – using the first “best guess” as a starting point for subsequent estimating;
  • Expert over-confidence – failure of creativity or hubris (e.g., “I know this information and can’t be wrong because I’m the expert.”);
  • Incentives – the SME experiences some benefit or cost in relationship to the outcome of the term being measured, adjusting his estimate in the direction of the preferred outcome;
  • Entitlement – the SME provides an estimate that reinforces his sense of personal value.
Without bias-free assessments in our decisions to actively pursue sales opportunities, it's nearly impossible to know how to allocate sales and support resources effectively to maximize the likelihood of capturing sales in a profitable and efficient manner. In short, when given the opportunity to pursue multiple opportunities with limited resources, it’s often difficult to know if any given opportunity is worth the time.

As odd as it may sound in a culture that seems to demand almost endless optimism, the Power of Negative Thinking actually helps us to overcome our biases as well as inform us how to obtain better information about the external uncertainties we face. By “negative thinking” we do not mean cynicism or toxic nay-saying. Rather, we refer to a process that asks us to consider critically the opposite of what we too easily assume (or wish) to be true. While Negative Thinking could lead us to consider the effects of unfortunate outcomes or conditions (the opposite of desired outcomes) on sales opportunities...

The best laid schemes o’ Mice an’ Salesmen, Gang aft agley


...it could also lead us to consider the possibility of desirable outcomes or conditions (the opposite of the unfortunate) for situations that we often easily dismiss.

No, no, boy, that's no way to make a plane. That'll, I say, that'll never...fly!

But the Power of Negative Thinking goes beyond our merely considering what can happen. We must also consider the “why” and “to what degree” those things could happen. We can account for the “what,” “why,” and “to what degree” in a process called probabilistic reasoning. But that's the second step. The Power of Negative Thinking begins with accurately framing an opportunity, which requires that a sales team answer the following questions:
  • What is the real opportunity? 
  • What are our goals and objectives?
  • What are the client's goals and objectives?
  • What are the decision boundaries and open decisions?
  • What are the sources of uncertainty? 
Answering these questions helps the team know that it has the right reasons in mind to pursue an opportunity and what constraints in their current level of knowledge limit their ability to make unambiguous decisions about what opportunities to pursue and how to go about pursuing them.

Probabilistic reasoning helps a sales team then answer these questions:
  • What is the likely range of outcomes for the uncertainties? 
  • What are the effects of uncertainties on sales goals, revenues, and profit? 
  • How much risk do we face with each opportunity; i.e., how much could we lose by pursuing one opportunity over another?
  • What insights can we create for contingency plans or options?
  • How do we prioritize our set of current opportunities?

The effect of taking these two steps in a structured way reveals the Power of Negative Thinking so that the sales team can recognize when an opportunity is worth pursuing…or not. Ultimately, not only does the Power of Negative Thinking give the sales team a more accurate assessment of the current state and possibilities they face, they can also develop more effective contingency plans to increase the likelihood of achieving results their organization—and their clients—desire.

A Decision Analyst's View of Electoral Surprise

I turned off the television last night at 8 PM. Since I had an analytics problem to work on, I didn't want my attention divided, and I knew that clinging to electoral results was more neurotic than helpful. My attention at the moment was not going to change the results. So, I rolled up my sleeves and got to work.

At 12:30 AM, I turned my television back on...


As I watched the polling results roll in and followed the reactions of establishment pundits and the broader hoi polloi (from both sides) in social media, all I could think was, "What is going on here?" Over and over. I mean, Nate Silver was still giving better than 2:1 odds of a Clinton victory just before I turned off the TV. Could the situation really have been that different than assessed? Could things really have changed that quickly? At 4 AM, I finally captured some thoughts that I think should serve as object lessons for all of us, and not just in politics, but in business, too.
  1. Never, ever believe your own spin. Humans love narratives that give them comfort. Unfortunately, almost all narratives are constructed from selected evidence that fits a preferred narrative.
  2. Always question where your biases are coming from. You are biased. Until you recognize it, you will frequently be rudely embarrassed. 
  3. There is no meaningful position in certainty. All beliefs about future events should be treated with degrees of belief. 
  4. Even events that happened in the past are open to interpretation. The real issue about the facts of events is not so much whether events have occurred in the past or whether they will occur in the future. The real issue is our epistemic distance from the events. We generally don't know as much as we think we do.
  5. We condition our beliefs on the evidence at hand. Thinking that a Clinton victory was highly probable was not a bad position to take. It made sense given much of the evidence. BUT, Prob(Clinton win) > 50% does mean Prob(Clinton win) = 100%! (I'm actually getting tired of explaining this. I'm getting tired of seeing people make this mistake and the effects it has in real life on real people. Probabilities are degrees of belief, not statements of fact.) Always, always, always consider the disconfirming evidence. 
  6. Trump never showed an insignificant chance of winning. His victory was always probable. What I see and hear coming from those expressing shocked disappointment about the Clinton loss is that they didn't really explore and consider the edge cases that would lead to a Trump victory. Explore the edge cases. Explore aggressively. Keep exploring. 
  7. Informed accuracy trumps false precision (pun intended). Don't be embarrassed to draw your prediction intervals wide. It's more honest, more informative, and will allow you to do a better job preparing contingency plans. When #6 is performed honestly and aggressively, it should lead you to make your prediction intervals even wider. It's better to be humble and recognize how little you know versus being sure and then being rudely surprised.
  8. The evolving probability of win curves for this election resemble the curves associated with predicting that a given hypothesis among several is true when there are unaccounted for characteristics at play. Suddenly, a seemingly most likely explanation crashes to be replaced by a previously less likely hypothesis as the unrecognized characteristic manifests itself. This is a long way to say people get caught up in false dichotomies (or n-chotomies) for the possible explanations for what really is the case. It is almost always the case that more explanations are available than the limited set we originally conceived.
  9. If something really weird happens and somehow the posted results at 4 AM reverse by the time I wake up, all of the above still applies, maybe more so.

Although Nate Silver was leaning in the wrong direction for predicting the outcome, his odds were actually more realistic and informed than many other pollsters who were giving 19:1 odds or better for a Clinton win.

Tuesday, September 27, 2016

New Book: Business Intelligence with R by Dwight Berry

If you are new to data science and learning the R language, let me recommend this new gem of a book, Business Intelligence with R, by my friendr (the term I just coined to describe R users who help each other), Dwight Barry: https://leanpub.com/businessintelligencewithr

Business Intelligence with R serves as a great cookbook that can save you hours of frustration learning how to get the basics going. Even if you're an old pro, the book serves as a handy desk reference.

Also, please consider the personal note that Dwight sent to all of his beta readers:
Perhaps most importantly, I've also decided to give all proceeds to the Agape Girls Junior Guild, which is a group of middle-school girls who do fundraising for mitochondrial disorder research at Seattle Children's Research Institute and Seattle Children's Hospital. While the minimum price for this book will always be free, if you're the type who likes to "buy the author a coffee," know that your donation is supporting a better cause than my already out-of-control coffee habit. :-)
Business Intelligence with R serves a greater cause.

Wednesday, February 10, 2016

Becoming a Business Analytics Jedi: An application of values-framed decision making

I will be speaking at the Georgia Tech Scheller College of Business on February 18, 2016 on the following topic:
In the current rush to adopt data-driven analytics, discussions about algorithms, programming tools, and big data tend to dominate the practice of business analytics. But we are defined by our choices, our values, and preferences. Data and business analytics that do not start with this recognition actually fail to support the human-centered reason for decision making. This is the way of the Sith. A Jedi, however, knows that framing business analytics in terms of the values and preferences of decision makers, and the uncertainty of achieving those, employs the tools of decision and data science in the wisest way. In this discussion, we will think about the principles of high quality decisions, how to frame a business analytics problem, and learn how to use information in the most efficient way to create value and minimize risk.
The discussion will include a demonstration of the Analytica modeling software.

If you're in the Atlanta area, I would love for you to join me in the discussion.

A special thanks to Dr. Beverly Wright for organizing this event!


Interview with Atlanta Business Radio

Recently, Brian McCarthy and I had some fun being interviewed by Ryan McPherson of Atlanta Business Radio.

You can listen to the interview here or here (starts @19:39).

Monday, January 19, 2015

Teaching the Love of Thinking and Discovery

This post is going to be different from what I've published here before. I'm not going explain something or attempt to be clever. Instead, I want to share an idea, an open ended kind of idea for which, at this point, I have no conclusions. First, let me share some background.

The other day I shared a TED Talk by Conrad Wolfram ("Teaching kids real math with computers") as an update on LinkedIn and on my personal Facebook. Please take the time to listen to this if you have not already. I think this is actually vitally important to the well being of our children and how they gain an education.

My friend and colleague, James Mitchell, made the following comment on the original update: "A great talk. My daughter's life would have been so much easier and better with this approach to teaching math. Wolfram talked about all her complaints." They were my complaints, too. A few of the comments made on my Facebook page included "Math is hard" and "I hate math. I never use it." Apparently, the same complaints are shared by more than just two people.

Curiosity photo by Rosemary Ratcliff, provided courtesy of FreeDigitalPhotos.net

I've been thinking about this TED Talk almost non-stop since I watched it, and I'm beginning to think that one way to achieve the idea here is to provide mathematics education outside of traditional school environments. By that, I don't mean that we should advocate that schools quit teaching math; rather, I think we need to start providing private forums in which kids who are interested in math can learn math in the same way they might learn and participate in extracurricular sports or arts activities that are not offered in a traditional school. I'm currently convinced the program must be private and free from policy driven curricula that "teaches to the test" and arbitrary performance criteria. This is for fun, but a special kind of fun.

What if there were mathematics/programming academies that taught math this way? Maybe it would be a private academy for self-motivated kids who want to learn math, maybe offered after their normal school day or on the weekends. It would follow the approaches advocated by Conrad Wolfram, Paul Lockhart, and Kevin Devlin. It would not confer a degree, diploma, or certificate of any sort other than a letter that describes the areas of inquiry and completion of certain milestone projects that were self-selected by the student and mentored by the "professors." For older students, these projects might include publishing papers in journals as well as serve as the submissions to more traditional math and science fair projects. This would not be an after school tutoring program for students who want to improve their grades to passing levels or gain extra points on their college admission tests.

In other words, the immediate purpose of the school would only be to satisfy the natural curiosity of self-motivated students. I believe such an academy would eventually provide economic benefits to its students because it would teach both creative and structured thinking that the market would eventually reward, but the near term benefit would serve to remediate the destruction of natural curiosity created in our current systems and just simply help our youngest achieve what they want to achieve. I envision this as a kind of math zendo where children learn the art driven by intrinsic motivation and encouragement from like-mined but more mature leaders.

Of course, as ideas take hold in our minds, so do the doubts. I think the difficult aspect of this idea would be financing the program. Currently, I see the finances being provided in part by student fees, some voluntary time offered by teachers, and private donations. I would want to structure the student fees such that an interested student could not participate because they could not afford the fees.

Much remains to be considered here. Maybe this has been done before or is being done right now. I don't know. Regardless, I welcome any feedback you might offer.