Traders work at Goldman Sachs booth on the floor of the New York Stock Exchange in New York.

A difficult first-quarter earnings season kicks off this week, and Goldman has some strategies for clients to beat the market during this likely tough trading environment.

After a record rally that gave stocks their best start to a year since 1998, investors are now faced with an earnings decline of 4.2%, the first loss in more than two years, versus a 12% gain in the fourth quarter, according to numbers from FactSet. As rising costs and slowing global demand continue to weigh on bottom lines and hurt sales, investors are finding themselves with almost nowhere to reap a profit.

Analysts at Goldman selected four 50-stock baskets from its secret portfolios with proprietary themes such as low labor costs, large dividends and big sales, which they think will work well in an economic and earnings slowdown. Then they winnowed the pool down to just 30 super stocks that share many of these traits, overlapping in at least two baskets.

All of Goldman's four baskets have outperformed in 2019, Goldman's chief U.S. equity strategist, David Kostin, said in the note Friday, advising clients where to invest in the second quarter. The 30 stocks that made the cut carry more than one defensive trait that can help withstand the pressure from higher costs and slowing growth.

For example, companies in the low labor cost basket allocate only 5% of sales to labor, as opposed to 27% for high labor cost companies. Goldman's high-dividend stocks are expected to grow dividends two times that of the S&P 500 firms through 2020.

A big chunk of the winning stocks are in the information technology sector, but there are lesser-known names including semiconductor manufacturer Texas Instruments, domain name provider Verisign and fintech company Western Union.

Other picks from Goldman include Amgen, Facebook, PayPal, Foot Locker and AT&T.

The bank expects U.S. economic growth to decelerate to 2.3% in 2019 and it calls for a 48% recession probability within the next three years. And Goldman has a S&P 500 year-end target of 3,000, which would represent a 4% gain from now.