TORONTO -- The Toronto stock market was in the red Tuesday as earnings from Bank of Montreal (TSX:BMO) missed forecasts and U.S. Federal Reserve chairwoman Janet Yellen continued to lay the groundwork for a hike in interest rates.

The S&P/TSX composite index fell 34.8 points to 15,165.46 as the energy sector lost early momentum even as oil prices advanced.

Bank of Montreal (TSX:BMO) posted lower earnings amid an "unsettled environment" that saw the bank deal with "significant movements in oil prices, long-term interest rates and the Canadian dollar."

Adjusted net income was $1.04 billion or $1.53 a share, a dime short of estimates and its shares were down $1.51 at $75.87. Most other bank stocks were also lower as traders anticipated earnings from the other four of the six major lending institutions reporting this week will report similar issues.

"Across the rest of the Canadian banks, we will see a lacklustre or challenging or slower growth environment from personal and commercial banking," said Colum McKinley, Canadian equities manager at CIBC Asset Management.

The Canadian dollar was 0.21 of a U.S. cent lower at 79.31 cents.

U.S. indexes were mainly higher as Yellen told the Senate finance committee that the U.S. central bank will continue to be patient in deciding when to hike interest rates. And she added that before rates go up, the central bank would drop this assurance.

There has been much speculation the bank could move on raising rates as early as June.

"Over time, if the U.S. economy continues to accelerate, we will inevitably get to the point where rates will move higher," McKinley said, "but the Fed is still managing that process of setting expectations around when that could happen and what it would look like."

The Dow Jones industrials gained 78.41 points to 18,195.25 and the S&P 500 index edged up 3.52 points to 2,113.18, while the Nasdaq dipped 1.01 points to 4,959.96.

March copper was up six cents at US$2.65 a pound and the base metals sector rose 3.6 per cent.

The TSX energy sector surrendered early gains to move down 0.5 per cent even as oil gained 26 cents to US$49.71 a barrel.

The gold sector was off 0.25 per cent as April bullion faded $3.50 to US$1,197.30 an ounce.

Canadian National Railway (TSX:CNR) arrived at a tentative agreement Monday with Unifor, which represents about 4,800 mechanical, intermodal and clerical workers, less than an hour after the railway's 11 p.m. ET deadline to lock out the union's members. CN declined 44 cents to $86.28.

Fertilizer company Agrium Inc. (TSX:AGU) turned in quarterly net earnings of US$51 million or 33 cents a share, down from US$99 million or 66 cents in the same 2013 period. Sales revenue fell by US$162 million to US$2.7 billion from just under US$2.9 billion. Its shares ran ahead $4.48 to $142.50.

There was also positive news for the eurozone. Greece's creditors in the 19-country currency union have approved a list of reforms Athens proposed to get a four-month extension to its bailout, which should keep the country afloat over the coming months.