Materials, financials push S&P/TSX composite lower but market rebounds in October