Source: Rite Aid Corporation

In the wake of Rite Aid Corporation's (RAD 24.00%) return to profitability, and recent worries over the government's falling reimbursements for drugs for Medicare and Medicaid patients, Rite Aid has become one of this past year's most volatile stocks.

In a bid to gauge whether or not Rite Aid can shake off its recent slide, I analyzed Rite Aid's balance sheet in a previous article and discovered that its balance sheet remains worrisome, but is improving.

Today, I want to take a look at Rite Aid's cash flow and see if there are clues to whether or not Rite Aid can get back on track there, too.

What is cash flow analysis?
Cash flow analysis is one of several ways that investors can gauge the health of a company because it shows investors how much money is coming into the business (and from where) and how much money is going out of the business (and to where).

As a result, cash flow analysis can be used to measure a company's liquidity and that liquidity can be just as important to a company's long term survival as its profitability. After all, plenty of profitable companies have ended up in bankruptcy because credit dries up and cash flow can't adequately cover debt payments.

Improving business
Let's begin by evaluating Rite Aid's free cash flow. Free cash flow is an important part of cash flow analysis, but not just because it's simple to use. Free cash flow shows investors how much cash from day-to-day operations is left over after spending money on capital expenses, such as new stores, distribution centers, or retail shelving.

At Rite Aid, you can see that the company's trailing-12-month free cash flow began falling sharply ahead of the recession and after the company's acquisition of the Eckerd drugstore chain in 2007. At its lowest point, Rite Aid's trailing-12-month free cash flow was roughly at negative $1 billion.

That's scary stuff; given that backdrop, it's not that surprising that some investors worried that Rite Aid would eventually find itself in bankruptcy court. In fact, fear over Rite Aid's liquidity got so high that Rite Aid shares tumbled to less than $1 in 2010.

Luckily for investors, that fear never materialized and Rite Aid's cash flow has been steadily improving since. Thanks to improving credit markets that allowed Rite Aid to refinance debt, and an aggressive store closing program that cut the number of Rite Aid locations from more than 5,000 in 2008 to less than 4,600 last quarter, free cash flow turned positive last year and totals $352 million for the 12-month period ending last quarter.

RAD Free Cash Flow (TTM) Chart

RAD Free Cash Flow (TTM) data by YCharts

Moving in the right direction
It can also be helpful to consider the trend in net operating income, which is calculated by adjusting net income for things like depreciation, lease terminations, and stock based compensation for employees. Rite Aid's net operating income totaled $122 million last quarter, up from $79 million a year ago.

And it helps to know whether companies are paying down their debt obligations, too; especially at companies like Rite Aid that are coming back from the verge of bankruptcy. Rite Aid's long term debt is high at $6.45 billion, but it's down from a peak of $7.5 billion. Since Rite Aid's debt load is falling and Rite Aid has refinanced debt to more favorable rates, Rite Aid's net interest expense is dropping too, falling from $135 million a quarter back in 2013 to $101 million last quarter.

The combination of rising net operating income and an improving debt picture is allowing Rite Aid to bulk up its cash, too. Rite Aid's cash and equivalents grew by nearly $20 million in the quarter to $185 million, up from $144 million a year ago.That cash will come in handy as Rite Aid transitions from a company that is restructuring to one that is growing again.

Work remains
Rite Aid remains a troubled company, albeit one that is far less troubled than it was just two years ago. The company's free cash flow suggests that the company will be able to cover its debt (for now), but investors will want to track the trend in cash flow as we go forward given Rite Aid's warning last quarter that lower government reimbursement revenue and higher generic prices are weighing on profitability.

Since Rite Aid's cash position is improving, investors can take solace in knowing that Rite Aid has some financial flexibility, albeit small, to invest some money back into its business. Those investments could prove vital to taking advantage of opportunities for growth tied to aging baby boomers and health care reform.