Banking is a tough business. It's fraught with risk. It's one of the most regulated industries in the world. The competition is ruthless. 

Some institutions have proven capable of thriving even in such a challenging environment. Others have fallen short. 

Today I'll discuss three institutions -- Popular, Inc (NASDAQ:BPOP), First Bank (NYSE:FBP), and Bank of America (NYSE:BAC) -- that have had significant problems, each of which highlights a key fundamental in bank investing today. 

It all starts with credit quality
Fundamentally, banks are in the business of making loans. From the community bank in your town to the largest bank in the world, the whole operation pivots on the ability of the bank to make profitable loans that get repaid.  Sounds simple enough, but history has proven how challenging this can be.

Popular, Inc is a great example. This $35 billion Puerto Rican bank has a serious credit quality problem, partially due to poor credit approval standards and partly due to the economic problems present throughout the Puerto Rican economy. Using the ratio of the bank's non-performing assets -- that is, severely past-due loans plus foreclosures -- relative to its total assets, Popular is one of the worst-performing banks under FDIC supervision.

According to the bank's first-quarter regulatory report, that ratio stands at 2.97%. For context, Bank of America's NPA ratio was just 0.85% for the same period (we'll come back to B of A later for another reason).

The problem with these high levels of poor credit is twofold. First, if the bank can't fix or recover enough of the troubled loans, the resulting losses can put the very existence of the bank in jeopardy. Second, even if the bank can manage through the problems, it's forced to devote serious resources to manage these problems. That can put a serious drag on earnings.

The moment just prior to a bank's failure, courtesy of the Texas Ratio
In the late 1980s, Texas banks lowered their credit standards en masse to finance the booming oil and gas explosion in the state. As the decade came to a close, oil prices plummeted, and those same Texas banks found themselves in a world of hurt. 

Researchers found a common pattern among those Texas banks that first struggled and then failed. They could predict the likelihood of a bank's failure with reasonable accuracy using a single and pretty simple ratio.

The Texas ratio, as it came to be known, is calculated by taking a bank's non-performing assets and dividing it by the sum of the bank's tangible equity and loan loss reserves. In other words, it's all the bank's problems divided by its back-up funds. 

If the problems become too large relative to capital and loan loss reserves, generally defined as a Texas ratio of 100% or higher, then it's more than likely the bank will fail. It's not a certainty, but it's indicative of a bank in serious trouble.

Of the 100 largest U.S. banks, no institution currently has a Texas ratio above 100%. For that matter, only one has a ratio above 40%. That bank, First Bank, again of Puerto Rico, scores a ratio of 60%. While that doesn't put the bank in immediate danger of failing, it does raise a big red flag with the worse Texas ratio among FDIC regulated banks. 

The top banks are lean and mean. Others are, well, less so.
A high-performing bank will almost always be an efficient bank. We can measure this with another aptly named ratio, the efficiency ratio. The lower the ratio, the better the efficiency.

Obviously, lower costs relative to revenue means higher profit. But there's a more subtle benefit to efficiency at banks. 

When a bank operates with elite cost control, it doesn't need much revenue to meet profitability targets. That's key, because all revenue is not good revenue.

Remember our discussion of credit quality above? Originating a bad loan will bring in revenue for a while. But when that loan falls behind, the losses can exceed any revenue generated hundreds of times over. The best banks avoid the bad revenue from poorly underwritten loans. And they still profit handsomely thanks to low costs. 

Instead of chasing lower-quality loans that would fetch higher interest rates, the best banks can afford to be picky. They can make competitively priced offers and win the highest quality loans, nipping any non-performing assets in the bud. 

Enter Bank of America. As of the first quarter of this year, B of A's efficiency ratio was 73.3%, which is actually a significant improvement from the bank's 2014 first quarter result of 97.7%. B of A is the worst of the megabanks, with Wells Fargo, Citigroup, and JPMorgan Chase each trouncing B of A with efficiency ratios of 58.8%, 55%, and 60% respectively.

Each of the banks here have fundamental problems that are significantly holding back performance. Taken altogether, they serve as an excellent case study in the factors that drive both success and failure in banking.

As an investor, I'd avoid these stocks, and instead seek out alternative banks with a proven record of high credit standards, conservative capital structures, and an efficient income statement.