Beware the banks. That's been the message for investors in the last couple of quarters, as banks corrected harder than the broad market during broad market's Q4 stumble, then rebounded less forcefully when the calendar flipped to 2019.

Since Oct. 1, the S&P 500 Banks Index is down about 3.3%, vs. the rest of the S&P 500 back above breakeven on the round-trip move.

But despite that lack of movement in the rearview mirror, the road ahead for some of the big banks is finally looking bullish.

In particular, it looks like Bank of America (BAC - Get Report) is in the final stages of carving out a long-term bottom - one that implies a 23% upside move. To figure out how to trade it, we're turning to the charts for a technical look:

Bank of America's price action might look erratic of late, but shares have actually been forming a pretty textbook example of an inverse head-and-shoulders pattern, a bullish reversal setup that signals exhaustion among sellers.

For BofA, the buy signal comes on a material breakout through this stock's neckline level, currently within grabbing distance right around $30.25.

Don't let the silly name fool you; the head and shoulders is an effective trading setup. An academic study conducted by the Federal Reserve Board of New York found that the results of 10,000 computer-simulated head-and-shoulders trades resulted in "profits [that] would have been both statistically and economically significant."

Longer term, things look equally bullish (and much simpler).

The weekly chart above shows a clear-cut uptrend in BofA stretching all the way back to this stock's 2012 lows. Shares have caught a bid higher like clockwork on every test of trendline support along the way - most recently at the end of December.

That fact adds some confidence to the idea that December's low is a significant line in the sand.

Right now, the inverse head-and-shoulders setup in the shorter-term chart implies up to a 23% upside move once the $30.25 level gets materially taken out.

Meanwhile, risk management remains key here. With the long-term trendline currently sitting right around $24, it makes sense to park a protective stop on the other side of that level. Simply put, if BofA violates $24, then the uptrend is over and you don't want to own it anymore.

Until then, this big bank looks like it's still got plenty of gas in the tank on the way up.

This article is commentary by an independent contributor. At the time of publication, the author held no positions in the stocks mentioned.