Swarm Intelligence

7,313 views

Published on

It contains about:-
Wht SI is about??
And how can we make Future stock prediction using SI??

Published in: Business, Economy & Finance
  • Be the first to comment

Swarm Intelligence

  1. 1. Introduction <ul><li>We will introduce a trading system for stock markets, which is designed as a framework for development and evaluation of intelligent decision-making models. </li></ul><ul><li>We will develop a model which is used to generate one-step forward investment decisions for stock market. </li></ul><ul><li>For Decision-Making in Stock market, more information processing tools are required. </li></ul><ul><li>Use of AI had made a mark on Investment Decision Technologies. </li></ul><ul><li>There are many stock trading systems which allow users to make technical and fundamental analysis of stock markets’ change. Systems like WinnerStockPicks,NasTradingSystem, </li></ul><ul><li>TradingForProfits generate trading signals and allow the users to make analysis of Stock Market Behavior through application of Technical Analysis. </li></ul>
  2. 2. What Is Artificial Intelligence?? <ul><li>It’s that area of Computer Science;focussed on creating machines that can engage on behaviors that humans consider intelligent. </li></ul><ul><li>AI is science and engineering of making intelligent machines. </li></ul><ul><li>AI doesn’t have to confine itself to methods that are biologically applicable . </li></ul>
  3. 3. Applications Of Artificial Intelligence!! <ul><li>Finance - Banks use AI to organize operations, invest in stocks and manage properties. </li></ul><ul><li>Games - There are games which play master level chess for 100 dollars. </li></ul><ul><li>Understanding Natural Language- neither sequence of words nor parsing is enough. Computer is to be provided with an understanding of domain text. </li></ul><ul><li>Medicine- Medical clinic uses AI to organize bed schedules, make staff rotation, provide medical info. </li></ul><ul><li>Artificial Neural networks are used for medical diagnosis. </li></ul><ul><li>Many other Applications Of AI includes the fields of Speech Recognition, computer vision and many more. </li></ul>
  4. 4. Swarm Intelligence <ul><li>Is modern AI discipline that is concerned with design of multiagent systems e.g.- robotics. </li></ul><ul><li>It is that discipline that deals with natural and artificial systems composed of many individuals using decentralized control and self-organization e.g.- colonies of ants and termites. </li></ul><ul><li>It deals with the study of self-organizing process in natural and artificial swarm systems. </li></ul>
  5. 5. Properties Of Swarm Intelligence System <ul><li>It is composed of many individuals. </li></ul><ul><li>The individuals are relatively Homogenous. </li></ul><ul><li>The interactions among the individuals are based on simple behavioral rules that exploit only local info. that the individuals exchange directly or via the environment. </li></ul><ul><li>The overall behavior of the system results from the interactions of individuals with each other and with their environment, that is, the group behavior self-organizes. </li></ul><ul><li>The behavior of each individual of the swarm is described in probabilistic terms: Each individual has a stochastic behavior that depends on his local perception of the neighborhood. </li></ul>
  6. 6. Applications Of Swarm Intelligence <ul><li>Clustering behavior of Ants :- The use of Swarm Intelligence in Telecommunication Networks has also been researched, in the form of Ant Based Routing.  Basically this uses a probabilistic routing table rewarding/reinforcing the route successfully traversed by each &quot;ant&quot; (a small control packet) which flood the network. Reinforcement of the route in the forwards, reverse direction and both simultaneously have been researched: backwards reinforcement requires a symmetric network and couples the two directions together; forwards reinforcement rewards a route before the outcome is known. </li></ul><ul><li>Crowd Simulation :-Artists are using swarm technology as a means of creating complex interactive systems or simulating crowds.  Tim Burton's  Batman Returns  was the first movie to make use of swarm  </li></ul>
  7. 7. Example Algorithms <ul><li>SI Consists of two types of Algorithms:- </li></ul><ul><li>Ant-Colony Optimization </li></ul><ul><li>Particle Swarm Optimization </li></ul><ul><li>ACO is a class of optimization algorithms modeled on the actions of ant colony. </li></ul><ul><li>ACO methods are useful in problems that need to find paths to goals. </li></ul><ul><li>In ACO, a set of software agents called &quot;artificial ants” search for good solutions to optimization problem transformed into the problem of finding minimum costs path on a weighted graph. </li></ul>
  8. 8. Why PSO was chosen?? <ul><li>PSO is a population based stochastic optimization technique for the solution of continuous optimization problems. </li></ul><ul><li>In PSO, a set of software agents called particles search for good solutions to a given continuous optimization problem. </li></ul><ul><li>It is used in decision making in stock markets as it allows the search of”best” ANN on current time and make decisions, based on performance </li></ul><ul><li>Also PSO, is the only algorithm that doesn’t incorporate survival of fittest, which features removal of some candidate population member. </li></ul>
  9. 9. Stock Trading System <ul><li>The complexity and ”noisiness” of stock markets cause difficulties in making real time analysis of it and forecasting its changes in the future. </li></ul><ul><li>So a collection of individuals often solves a problem better than an individual. </li></ul><ul><li>Our main objective is to develop a method based on AI tools and apply it for the decisions making in stocks’ trading market. </li></ul><ul><li>PSO is population based algo. Based on simulation of social behavior among individuals. </li></ul><ul><li>Each particle here represents a candidate solution to the optimization of problem. </li></ul><ul><li>The optimizer used in PSO algo. Is similar to crossover operation used by genetic algorithms. </li></ul><ul><li>Also PSO includes FITNESS Function, measures the closeness of corresponding solution to optimum. </li></ul>
  10. 10. Stock Trader V/s Stock investor <ul><li>Stock Trader </li></ul><ul><li>Individuals trading stock on stock markets. </li></ul><ul><li>They usually try and gain profit from short-term price volatility. </li></ul><ul><li>He is a professional. </li></ul><ul><li>Stock Investor </li></ul><ul><li>Individuals who purchase stocks with the intention of holding for an extended period of time. </li></ul><ul><li>They usually hold stocks for several months to years. </li></ul><ul><li>They rely on fundamental analysis for their investment decisions. </li></ul>
  11. 11. Expenses,Cost And Risks <ul><li>Trading activities have high level of risk, uncertainity and complexity. </li></ul><ul><li>Stock trader/investor faces huge cost in form by the jurisdiction commissions, taxes & fees for the brokerage. </li></ul><ul><li>Taxes are charged over the transactions, dividends and capital gains. </li></ul><ul><li>Expenses like electricity, currency risk, opportunity cost of money and time and news agency are also added. </li></ul>
  12. 12. Artificial Neural Networks <ul><li>Model based on biological neural networks. </li></ul><ul><li>It consists of an interconnected group of artificial neurons and processes information . </li></ul><ul><li>We will be using Single Layer Neural Network . </li></ul><ul><li>It consists of a single layer of output nodes; the inputs are fed directly to the outputs via a series of weights. </li></ul>
  13. 13. What is the need for developing a Trading system?? <ul><li>The need of framework for testing stock trading algorithms and strategies. </li></ul><ul><li>The need of real time data for the analysis of trading algorithms. </li></ul><ul><li>The need to increase speed of computations. </li></ul>
  14. 14. Trading system architecture <ul><li>It’s divided into 3 parts:- external data, trade strategies and framework. </li></ul><ul><li>External data is used to retrieve real time or historical stock data. </li></ul><ul><li>Framework is used to download data from external data source ; to pre-process downloaded data and store it in the database. </li></ul><ul><li>The main requirements for the developed framework was to provide common interfaces for trading strategies and in this way to ensure easy integration of new trading. </li></ul>
  15. 15. How PSO Will Help?? <ul><li>PSO is based on the search of ”global best” particle. </li></ul><ul><li>” Global best” particle is chosen for every day taking into account the chosen moving time interval. </li></ul><ul><li>It means that every day we are comparing the performance (fitness function) of NN and the network with the highest performance is chosen for further experimental investigations. </li></ul><ul><li>The adaptation of the other particles weights is made towards the weights of “ global best ” particle. </li></ul><ul><li>Such adaptation of weights and training of NN will move to the best solution as all the time the trading decision are made using NN that have shown the best performance. </li></ul><ul><li>Knowing the day and NN, which performance was the best on that day, we select 3 stocks with the highest recommendations. </li></ul><ul><li>After this calculation of the prices’ change mean of 3 stocks with the highest recommendations is made which will let us achieve the best gain on next trading day. </li></ul>
  16. 16. Experimental Investigations <ul><ul><li>All the experimental investigations were run using daily stock returns of 350 stocks. </li></ul></ul><ul><ul><li>These stocks were selected from SP500 index group. </li></ul></ul><ul><ul><li>The recommendations for the purchase of the stock were formed using ”single layer” NN. </li></ul></ul><ul><ul><li>All the recommendations were sorted and for every day three stocks with the highest recommendations were chosen. </li></ul></ul><ul><ul><li>The price changes of chosen stocks on the next day were explored. </li></ul></ul><ul><ul><li>There were calculated expected day profits, taking into account the price changes of chosen stocks and the profit estimations was made selecting different moving time intervals. This profit was calculated as a sum of stock prices changes (%). </li></ul></ul><ul><ul><li>The PSO algorithm was applied and the profit estimation based on the search of ”global best” particles was made. </li></ul></ul><ul><ul><li>The experiments were run taking into account different number of NN and different size moving time intervals in order to find the situations when the best and the most stable results could be achieved. </li></ul></ul>
  17. 17. Selection of Moving Time Interval and Neural Networks <ul><li>The experiments were run taking into account different size moving time intervals and different number of NN. </li></ul><ul><li>Here, the commission fee for selling and buying stocks was not considered. </li></ul><ul><li>Following conclusions were found: </li></ul><ul><li>The bigger number of NN, with different initial weights, more stable results (see Fig. 1 and 2). </li></ul>
  18. 18. Selection Of Moving Time Interval And Neural Networks <ul><li>The bigger moving time intervals let to avoid unnecessary variations and to achieve better results (see Fig. 3). </li></ul><ul><li>The experimental investigations showed that the best results are achieved while taking 30 NN and the moving time interval of 100 days. </li></ul><ul><li>Fig. 3 shows how the profit (% per day) is correlated with the different size moving time intervals while exploring 30 NN. Here numbers 1, 2, ...,10 represent time intervals 10, 20, ..., 100 respectively. </li></ul><ul><li>From the Fig. 3, the profit is growing while increasing moving time intervals. The variations of the profit become more stable while having moving time intervals from 70 to 100 days (see Fig. 4). </li></ul>
  19. 19. Continued.. <ul><li>The performance of the model was increased by deciding the combination of “global best” particles selection and training of ANN. </li></ul><ul><li>It was made through the selection of the group of “global best” particles instead of selecting one “global best” particle for decision-making. </li></ul><ul><li>The decision-making was made according to the recommendation of the top “global best” particle, while the ANN training procedure was based on the average performance of selected group of the particles. </li></ul><ul><li>In Table we are having different sets of particles. The average performance (profit estimation (%)) and standard deviation of each case are presented. </li></ul>
  20. 20. Conclusion And future work <ul><li>We presented the decision-making model based on the application of the ANN and PSO algorithms. </li></ul><ul><li>The experimental investigations have shown that the application of set of particles for the training of ANN can give better results than training of ANN based on the performance of only one global best particle. </li></ul><ul><li>The bigger number of NN and longer moving time interval let us to achieve better and more stable results. </li></ul><ul><li>In future we intend to extend the current trading system with new features: more frequent trading possibilities, more detailed analysis possibilities. </li></ul>

×