Executive trading is a kind of investment strategy that analyses and models the financial market with mathematical methods. Machine learning requires computer programs to improve their performance at specific tasks by learning on data sets. Both require the extraction of information from data, so with the success of machine learning in recent years, there has been a strong interest in the combination of executive trading and machine learning methods in both industry and academia. In this paper, based on machine learning is complete, a more complete model of data processing - build - generated forecast - trading strategy - back-test analysis “research framework, and discusses the structures of branching and merging model structure set up, based on the value relevance of the output value and supervision model selection criteria, independently of the back and trading strategy model assessment method and a series of important issues. This paper focuses on the innovative exploration of the application of the loss function, and puts forward several loss functions based on the portfolio point of view, among which the negative cosine loss function shows significant advantages and strong practicability in stability and gain. Corresponding empirical research also reveals the application value and limitation of other loss functions.