TRADE SMART Zihao Yu Kevin Bobsein Ashrith Kumar Marpaka Hanzhi Wu Instructor : Prof. Ivan Marsic...

Preview:

Citation preview

TRADE SMART

Zihao Yu Kevin Bobsein Ashrith Kumar Marpaka Hanzhi Wu

Instructor : Prof. Ivan Marsic

Partial fulfillment of the course Software Engineering -2 for web applications

16:332:568 Spring 2009

DATE: 05/08/2009

PAST

• Stock markets and Indices

• Introduction to Technical analysis

• Fundamental Analysis

• Indicators

• Work Plan

• System Architecture

• Use cases

• Web services

LIFE CYCLE

• System design

• Data collection

• Website development

• Web Service

• XML Schema

• Indicators

• Patterns

• Integration

• Test and RUN

LABOR

System Architecture

• Four tier architectureclient

web server

database

modules

System block instruction

Use Case DiagramCreateAccount

ManageFile

GetGraphs

User

Login

<<extend>>

<<extend>>

GetQuotes

<<include>>

GetIndicators

GetPattern

GetPredictedprice

Administrator

<<participate>>

<<participate>>

<<participate>>

<<participate>>

<<participate>>

<<initiate>>

<<initiate>>

<<initiate>>

<<initiate>>

<<initiate>>

Name Login

Participating actors

Initiated by AdministratorCommunicates with Users

Flow of events 1. The Administrator requests the creation of the login function. 2. The user inputs his/her name, and password to create the account. Then he/she inputs his/her name and password again to log in the system.3. webpage is displayed, showing some latest news and some important stock’s graphsdynamically.

Name GetQuotes

Participating actors

Initiated by AdministratorCommunicates with Users

Flow of events 1. The Administrator creates the GetQuotes 2. The user logs in into the webpage, and click Getquote button, get the stock information he need from yahoo, such as the start price, end price, volumns.

Name GetIndicator

Participating actors

Initiated by AdministratorCommunicates with Users

Flow of events 1. The Administrator creates GetIndicator. 2. The user selects the past data, for example, select the past 10 ending prices and then gets the indicator such as buy, sell or hold according to the moving average.Name GetPredictedprice

Participating actors

Initiated by AdministratorCommunicates with Users

Flow of events 1. The Administrator creates GetPredictedprice. 2. The user chooses the model, and get the price predicted by the model he choose.

Name GetPattern

Participating actors

Initiated by AdministratorCommunicates with Users

Flow of events 1. The Administrator creates the GetPattern. 2. The user choose the collects the data from the past days, and gets the predicted pattern.

Web Service Interface

• Software Stack– Apache Tomcat 5.5– Axis 1.4– Java 1.6

• Architecture– Services hosted by

Axis, served out by Apache, implemented using Java

Apache Tomcat

Axis

Stock Predictor and

Recommendation Service

Java Runtime

Interface APIgetPrediction(String)

getPrediction(String, String)

getPrediction(String, String, String)

IN

OUT

Issues Encountered

• Minimal documentation– All documentation available on the Web seems to be cut

and paste from the main Axis project page. – All tutorials are extremely simple and don’t go much

beyond “type these commands”, little description of what you’re actually doing

• Continually running into package/URN mapping issues– Sometimes the actual interface class just wouldn’t be

generated• Lack of logical built-in directory structure

– Due to Java dependence on packages, requirement that everything be placed in specific locations, unfortunately these locations aren’t very intuitive

Moving Average

• Implemented in Java

• If Today’s Moving Average from the last 15 days is > Yesterday’s Moving Average over the last 15 days, Buy

• If Today’s Moving Average from the last 15 days is < Yesterday’s Moving Average over the last 15 days, Sell

INDICATORS

• RELATIVE FLOW INDEX

• STOCHASTIC OSCILLATOR

• MOVING AVERAGES

• PRICE MOMENTUM

OSCILLATOR

• MONEY FLOW INDEX

• DEMARKER INDICATOR

• WILLIAMS INDICATOR

• COMMODITY CHANNEL INDEX

•AROON INDICATOR

•RATE OF CHANGE

•MOVING AVERAGES

•CONVERGENCE/DIVERGENCE

•ACCUMULATION/

DISTRIBUTION LINE

•PRICE CHANNEL ULTIMATE

OSCILLATOR

Patterns

• Four patterns can be recognized.– Double Bottom

– Double Top

– Ascending Triangle

– Descending Triangle

PATTERNS

Reality Training data(Generated using piecewise functions)

Pattern Recognition

Web Interface

Download Data

RSS Parser

• Use Magpie PHP library.– Object cache, enhance performance.

• Our work: parsing tags in XML.

Where AJAX is used

How

• jQuery Framework– Simplifies JS: event handling, AJAX interactions, etc

Database

CONCLUSION

• Achievements

• What did we learn ?

• Further improvements .. !!

THANK YOU !!!!!!

DEMO

Recommended