Every day, Wall Street analysts upgrade some stocks, downgrade others, and "initiate coverage" on a few more. But do these analysts even know what they're talking about? Today, we're taking one high-profile Wall Street pick and putting it under the microscope...

Investors snubbed GrubHub (NYSE:GRUB) yesterday.

After the online take-out service reported disappointing fiscal Q4 earnings -- and even more disappointing guidance -- GrubHub stock initially tumbled as much as 20% in price before recovering to close the day down just 2%. Today, however, investors are thinking completely different about GrubHub, and the stock is up nearly 5%.

You can thank Merrill Lynch and Roth Capital for that.

Woman excited over receiving pizza delivery

Not all investors were excited about GrubHub's Q4 earnings -- but these two analysts are. Image source: Getty Images.

Upgrading GrubHub stock

Both these bankers, you see, decided to upgrade GrubHub stock after earnings this morning, and both think it's a buy, according to notes covered on TheFly.com.

Merrill Lynch argues that GrubHub's less-than-expected sales growth in Q4 and its prediction of weaker-than-hoped-for earnings before interest, taxes, depreciation, and amortization (EBITDA) in 2019 are now priced into the stock. Furthermore, Merrill believes that the investments the company is making in expanding delivery to new markets will both take it down to the low point on profit margins and lay the groundwork for strong sales growth in the future.

Indeed, the acceleration of GrubHub's business is "just beginning," says Merrill Lynch, and for that reason, the analyst is increasing its estimates for 2019 and 2020 sales -- and raising its price target to $108 a share.

Upgrading GrubHub stock, part deux

Roth Capital seconds that emotion. In a twin upgrade to Merrill's, the analyst agrees that "better growth" will be the end result of GrubHub's investments, and that this will yield "improving unit economics long-term." Upgrading the stock to buy, and assigning a somewhat more conservative price target of $95 a share ($10 above where GrubHub trades today), Roth emphasizes the company's healthy 22% increase in diners year over year as proof that its investments are paying off.

And in fact, I think "paying off in spades" might not be too strong a way to describe it.

Consider: Last quarter, GrubHub reported daily average order growth of 19% and 22% growth in "active diners." But actual revenue at GrubHub increased twice as fast, which shows that users are placing larger and larger orders with its service, indicating rising confidence in the company's value proposition -- and promising bigger profits for GrubHub.

What's more, even analysts with buy ratings who reduced their price targets on GrubHub today appear optimistic about the company's chances. Craig-Hallum, for example, cut its price target to $120, but noted that the company increased the number of delivery markets it services by about 125 in Q4 -- 25 more than it had previously promised. At the rate GrubHub is expanding, Craig-Hallum argues there's a case to be made for the company potentially growing revenue as much as 31% to 41% faster than it's currently guiding investors to expect.

Why GrubHub's investments might make sense

True, there are costs to such rapid growth. Costs outran sales growth in the quarter, rising 62% year over year. Contrary to what you may have heard, however, most of this increase in spending was not marketing spending needed to combat competition from rivals like UberEats and Postmates. Rather, the vast majority of GrubHub's spending last quarter -- $144.1 million of total costs, or about half the company's revenue -- was spent on "operations and support." These costs jumped 76.5% year over year.

Granted, much of this spending will be a recurring cost of doing business (and thus eat into profit). According to GrubHub's 10-K filings, "operations and support" encompasses such ongoing costs as salaries, wages, bonuses, and "payment processing costs." That being said, "operations and support" spending also covers durable, longer-term capital investment like building out a library of online restaurant menus and facilities costs -- spending that will be longer-lived, and yield dividends for years to come.

Check out the latest GrubHub earnings call transcript.

Valuing GrubHub

In this regard, it's worth noting that GrubHub spent $43 million on such capex last year -- or about as much as it spent in 2016 and 2017 combined -- yet still managed to generate positive free cash flow of $182.5 million, which was more than twice its reported net income. And in that regard it's worth pointing out:

Valued on GAAP earnings alone, GrubHub stock looks extremely expensive at a P/E ratio of 95. But valued on its more substantial free cash flow, it's more reasonably priced at about 41 times FCF, and could look cheaper still if analysts are right, and GrubHub will be able to cut back on its investment spending after 2019, permitting its cash to flow more directly to the bottom line.

Long story short? I'm still not 100% certain that 41 times FCF isn't too much to pay for GrubHub shares, but if sales and earnings grow as fast as analysts like Merrill Lynch, Roth, and Craig-Hallum are predicting, the stock could still be a buy despite its high price tag.