Stock trading strategy plays a crucial role in investment companies. However,it is challenging to obtain optimal strategy in the complex and dynamic stockmarket. We explore the potential of deep reinforcement learning to optimizestock trading strategy and thus maximize investment return. 30 stocks areselected as our trading stocks and their daily prices are used as the trainingand trading market environment. We train a deep reinforcement learning agentand obtain an adaptive trading strategy. The agent's performance is evaluatedand compared with Dow Jones Industrial Average and the traditional min-varianceportfolio allocation strategy. The proposed deep reinforcement learningapproach is shown to outperform the two baselines in terms of both the Sharperatio and cumulative returns.