Management’s discussion and analysis Treasury and  CIO  overview Treasury and CIO  is  predominantly responsible for measuring, monitoring, reporting and managing the Firm’s liquidity, funding, capital, structural interest rate and foreign exchange risks. The risks managed by Treasury and CIO arise from the activities undertaken by the Firm’s four major reportable business segments to serve their respective client bases, which generate both on- and off-balance sheet assets and liabilities. Treasury and CIO seek to achieve the Firm’s asset-liability management objectives generally by investing in high-quality securities that are managed for the longer-term as part of the Firm’s investment securities portfolio. Treasury and CIO also use derivatives to meet the Firm’ s asset-liability management objectives. For further information on derivatives, refer to Note 5. In addition, Treasury and CIO manage the Firm’s cash position primarily through depositing at central banks and investing in short-term instruments. For further information on liquidity and funding risk, refer to Liqui dity Risk Management on  pages 95–100.  For informatio n on interest rate, foreign exchange and other risks, refer to M arket Risk Management on  pages 124–131. The investment securities portfolio primarily consists of agency and nonagency mortgage-backed securities, U.S. and non-U.S. government securities, obligations of U.S. states and municipalities, other ABS and corporate debt securities. At December 31, 2018, the investment securities portfolio was $260.1 billion, and the average credit rating of the securities comprising the portfolio was AA+ (based upon external ratings where available and, where not available, based primarily upon internal ratings that correspond to ratings as defined by S&P and Moody’s). Refer to Note 10 for further information on the Firm’s investment securities portfolio. As permitted by the new hedge accounting guidance, the Firm elected to transfer certain investment securities from HTM to AFS in the first quarter of 2018. For additional information, refer to Notes 1 and 10. Selected income statement and balance sheet data As of or for the year ended December 31, (in millions) 2018 2017 2016 Investment securities gains/(losses) $ $_{(395)}$  $ (78) $ 132 Available-for-sale (“AFS”) investment securities (average) 203,449 219,345 226,892 Held-to-maturity (“HTM”) investment securities (average) 31,747 47,927 51,358 Investment securities portfolio (average) 235,197 267,272 278,250 AFS investment securities (period- end) 228,681 200,247 236,670 HTM investment securities (period-end) 31,434 47,733 50,168 Investment securities portfolio (period–end) 260,115 247,980 286,838 JPMorgan Chase & Co./2018 Form 10-K 78