algorithmic google on streaming prices _technical&fundamentalanalyses + portfoliomgt

72
Finding the Right Product via Finding the Right Product via Real Real - - time Intelligent Internet time Intelligent Internet Search Services Solutions & BI Search Services Solutions & BI Tools on Streaming Prices Tools on Streaming Prices FOCUS ON FINANCIAL ANALYTICS & INFO FOCUS ON FINANCIAL ANALYTICS & INFO - - UTILITIES SOFTWARE APPLICATION UTILITIES SOFTWARE APPLICATION By Guan Seng Khoo*, PhD By Guan Seng Khoo*, PhD Online info Online info - - analytics, BI and CRM tools catering to all analytics, BI and CRM tools catering to all clients that trade at an institutional/retail site clients that trade at an institutional/retail site Email: Email: Khoo.Guan Khoo.Guan - - [email protected] [email protected] [email protected] [email protected]

Upload: guan-khoo

Post on 14-Jun-2015

119 views

Category:

Economy & Finance


4 download

DESCRIPTION

Pre-Big Data Analytics (Algorithmic Google on Streaming Prices): Analytical tools which perform real-time analysis for trading/investment decisions, catered to different types of investors, incl. day-trading, swing-trading & system trading. Think of it as a convenience store ("7-Eleven") of real-time trading ideas

TRANSCRIPT

Page 1: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Finding the Right Product via Finding the Right Product via

RealReal--time Intelligent Internet time Intelligent Internet

Search Services Solutions & BI Search Services Solutions & BI

Tools on Streaming PricesTools on Streaming PricesFOCUS ON FINANCIAL ANALYTICS & INFOFOCUS ON FINANCIAL ANALYTICS & INFO--

UTILITIES SOFTWARE APPLICATIONUTILITIES SOFTWARE APPLICATION

By Guan Seng Khoo*, PhDBy Guan Seng Khoo*, PhD�� Online infoOnline info--analytics, BI and CRM tools catering to all analytics, BI and CRM tools catering to all clients that trade at an institutional/retail siteclients that trade at an institutional/retail site

�� Email: Email: [email protected]@standardchartered.com

�� [email protected]@gmail.com

Page 2: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Example: TurboExample: Turbo--charging Technical charging Technical

Analysis with realAnalysis with real--time Internet time Internet

Search Tools on Streaming PricesSearch Tools on Streaming Prices

ExEx--SVP, American Bourses Corporation*SVP, American Bourses Corporation*

In partnership with Townsend Analytics & Terra In partnership with Townsend Analytics & Terra Nova Trading, ChicagoNova Trading, Chicago

(*Spin(*Spin--off co. of the Man Group)off co. of the Man Group)

*Headed a team of financial engineers & *Headed a team of financial engineers & quantsquants that designed & managed the Manthat designed & managed the Man--DrapeauDrapeau Response Fund, an algorithmic hedge Response Fund, an algorithmic hedge fund in the 90sfund in the 90s

Page 3: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Introductory RemarksIntroductory Remarks�� The following slides illustrate the use of an Intelligent InternThe following slides illustrate the use of an Intelligent Internet Search et Search

Engine with Tools applied on Streaming Prices (realEngine with Tools applied on Streaming Prices (real--time) for the time) for the Financial MarketsFinancial Markets

�� For identifying instruments that meet the userFor identifying instruments that meet the user’’s criteria in terms of s criteria in terms of

�� CapitalCapital

�� RiskRisk

�� investment horizoninvestment horizon

�� etc. etc.

�� Allows users to study the consistency of individual stockAllows users to study the consistency of individual stock’’s (or asset s (or asset classclass’’) historical risk) historical risk--return performance. return performance.

�� Allows users to compare the historical performance of selected Allows users to compare the historical performance of selected instruments instruments

�� For analyzing the historical riskFor analyzing the historical risk--return performance of various asset return performance of various asset classes. classes.

�� e.g., based on comparative study of the riske.g., based on comparative study of the risk--return performancereturn performance of of securities that fall within the same category, e.g. Banking sectsecurities that fall within the same category, e.g. Banking sector.or.

Page 4: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Introductory RemarksIntroductory Remarks

�� Readers may require some basic knowledge of Readers may require some basic knowledge of

trading and investment to appreciate the trading and investment to appreciate the

contentscontents

�� Previously in 2000Previously in 2000--2002, we 2002, we overlayedoverlayed our our

webweb--based search tools on based search tools on RealTickRealTick, the , the

intelligent trading and orderintelligent trading and order--routing system, routing system,

owned by Townsend Analytics (Chicago) owned by Townsend Analytics (Chicago)

�� Thank You Thank You

Page 5: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– TurboTurbo--charging TAcharging TA

�� Successful trading involves discipline and Successful trading involves discipline and

rigorous methods of analyses:rigorous methods of analyses:

�� FundamentalsFundamentals

�� TechnicalsTechnicals

�� Dynamic Asset AllocationDynamic Asset Allocation

�� DiversificationDiversification

Page 6: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– TurboTurbo--charging TAcharging TA

�� Some traditional ways of using technical Some traditional ways of using technical analysis include:analysis include:

�� Visual AnalysisVisual Analysis

�� Indicator AnalysisIndicator Analysis

�� Historical BackHistorical Back--testingtesting

�� These continue to be useful and form the core These continue to be useful and form the core body of knowledge and practice among technical body of knowledge and practice among technical traderstraders

Page 7: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 8: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 9: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 10: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– TurboTurbo--charging TAcharging TA

�� However, these methods go back a long time:However, these methods go back a long time:

�� Visual Technical Analysis Visual Technical Analysis –– Edwards and Magee have Edwards and Magee have

been around since the 1920s and we have just reached been around since the 1920s and we have just reached

the umpteenth edition that looks essentially the same. the umpteenth edition that looks essentially the same.

Computers plot the charts but the tools are the same.Computers plot the charts but the tools are the same.

�� Indicators still use the same algorithms that were once Indicators still use the same algorithms that were once

calculated by simple calculators such as Wildercalculated by simple calculators such as Wilder’’s RSI.s RSI.

�� Historical backHistorical back--testing, from the days of testing, from the days of ComputracComputrac and and

TeletracTeletrac, still crunch data the same old way : brute, still crunch data the same old way : brute--force force

testing of technical indicators.testing of technical indicators.

Page 11: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– TurboTurbo--charging TAcharging TA

�� While there is truth in not trying to fix something While there is truth in not trying to fix something

that that ““ainain’’tt brokebroke””, it is valid to ask, is it possible to , it is valid to ask, is it possible to

make technical analysis better?make technical analysis better?

�� Some interesting questions:Some interesting questions:

�� Can we do large scale screening of stocks before we Can we do large scale screening of stocks before we

interpret their chart patterns?interpret their chart patterns?

�� Can we improve some indicators to make better use of Can we improve some indicators to make better use of

computer technologies?computer technologies?

�� Can we use better dataCan we use better data--mining techniques to improve mining techniques to improve

on on backtestingbacktesting??

Page 12: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– TurboTurbo--charging TAcharging TA

�� In all these ways, there is still a need for trader In all these ways, there is still a need for trader

decision making decision making –– trader input is always required trader input is always required

for good trading results to be attainable.for good trading results to be attainable.

�� While there may be some better systems than While there may be some better systems than

others, there is nothing out there which has a others, there is nothing out there which has a

perfect track record. There is no Holy Grail or perfect track record. There is no Holy Grail or

silver bullet.silver bullet.

�� But we can, using modern computer techniques, But we can, using modern computer techniques,

turboturbo--charge traditional technical analysis.charge traditional technical analysis.

Page 13: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– TurboTurbo--charging TAcharging TA

�� Information technology has made the greatest Information technology has made the greatest

advance advance collecting datacollecting data..

�� Having data is very important Having data is very important -- the creation of the creation of

raw data is the equivalent of having discovered raw data is the equivalent of having discovered

““therethere’’s gold in them hillss gold in them hills””. Now, we have . Now, we have

literally mountains of data (which is what literally mountains of data (which is what

Google does best on static data).Google does best on static data).

�� We have to use the appropriate tools to mine We have to use the appropriate tools to mine

and find the nuggetsand find the nuggets

Page 14: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– TurboTurbo--charging TAcharging TA

�� The premise is that, with so much data The premise is that, with so much data (27,000 publicly traded US securities in 2002, (27,000 publicly traded US securities in 2002, in every barin every bar--size conceivable) size conceivable) collectedcollected, it is , it is possible to use datapossible to use data--mining (scanning, mining (scanning, screening etc) to narrow down to a screening etc) to narrow down to a reasonable number of situations, whether reasonable number of situations, whether these are securities or bar sizes, to make it these are securities or bar sizes, to make it easier to apply traditional techniques, easier to apply traditional techniques, analyzeanalyze them correctly and make a good them correctly and make a good trade.trade.

Page 15: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– TurboTurbo--charging TAcharging TA

�� One way to is to do DataOne way to is to do Data--MiningMining

DataData--Mining has been called by various less Mining has been called by various less

intimidating names :intimidating names :

�� Screening Screening

�� ScanningScanning

�� PreprocessingPreprocessing

�� MappingMapping

�� VisualizingVisualizing

Page 16: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– TurboTurbo--charging TAcharging TA

�� Use Data Mining to limit oneUse Data Mining to limit one’’s s

trading universe, so that it is possible trading universe, so that it is possible

to apply technical analysis fruitfully, to apply technical analysis fruitfully,

AND yet retain the flexibility to shift AND yet retain the flexibility to shift

focus to where the action is.focus to where the action is.

Page 17: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– TurboTurbo--charging TAcharging TA

�� What exactly is DataWhat exactly is Data--Mining the streaming prices Mining the streaming prices ala Google?ala Google?

�� In our context, it is the study of historical data to In our context, it is the study of historical data to understand relationships among instruments and understand relationships among instruments and their environment. their environment.

�� Examples:Examples:�� what kind of price and volatility behavior does a what kind of price and volatility behavior does a particular instrument normally have?particular instrument normally have?

�� How does it normally trade at different times of day, How does it normally trade at different times of day, days of week, or seasons of year etc? days of week, or seasons of year etc?

�� How instruments are correlated with others?How instruments are correlated with others?

�� How does a stock behave within its sector? How does a stock behave within its sector?

Page 18: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– TurboTurbo--charging TAcharging TA

More Examples:More Examples:

�� what kind of conditions would be most what kind of conditions would be most

appropriate for the successful application of appropriate for the successful application of

Moving Averages? Or Oscillators?Moving Averages? Or Oscillators?

�� What time bar tends to be useful for trading a What time bar tends to be useful for trading a

particular stock?particular stock?

�� Show data in maps and picturesShow data in maps and pictures

Page 19: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Interpreting Interpreting

Context/EnvironmentContext/Environment

�� Applications of DataApplications of Data--Mining in TA:Mining in TA:

�� Interpreting Context/EnvironmentInterpreting Context/Environment

�� Interpreting RiskInterpreting Risk

�� Analytical SupportAnalytical Support

�� VisualizationVisualization

��Narrowing ChoicesNarrowing Choices

Page 20: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Interpreting Interpreting

Context/EnvironmentContext/Environment

�� We need to understand We need to understand ““contextcontext”” or or ““environmentenvironment”” in order that we do the right things in order that we do the right things in the trading process.in the trading process.

�� With that said, it sounds dangerously close to what With that said, it sounds dangerously close to what people have called people have called ““curve fittingcurve fitting””

�� It is possible that a pedantic approach to dataIt is possible that a pedantic approach to data--mining will glean nothing from history to apply to mining will glean nothing from history to apply to our benefit for trading the future.our benefit for trading the future.

�� However, judiciously applied, knowing more about However, judiciously applied, knowing more about an instrumentan instrument’’s history prepares us better for the s history prepares us better for the future.future.

Page 21: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Interpreting Interpreting

Context/EnvironmentContext/Environment

�� Examples of good dataExamples of good data--mining exercises:mining exercises:

�� You want to trade stock XYZ. It would be a You want to trade stock XYZ. It would be a

good idea to find its good idea to find its ““pairspairs”” which are stocks which are stocks

which trade in a way which is either very similar, which trade in a way which is either very similar,

or completely contrary, to the movements of or completely contrary, to the movements of

XYZ. XYZ.

�� In the jargon, we need to look for uncorrelated In the jargon, we need to look for uncorrelated

as well as correlated stocksas well as correlated stocks

�� Here are examples:Here are examples:

Page 22: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Interpreting Context/EnvironmentInterpreting Context/Environment

Uncorrelated Stocks 1Uncorrelated Stocks 1

Page 23: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 24: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 25: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Interpreting Interpreting

Context/EnvironmentContext/Environment

�� Knowing what stocks are correlated or Knowing what stocks are correlated or

uncorrelated with the ones you are primarily uncorrelated with the ones you are primarily

interested in provides you with a pertinent interested in provides you with a pertinent

universe of stocks to confirm technical signals, universe of stocks to confirm technical signals,

and to implement risk management positionsand to implement risk management positions

�� Buy/sell laggardsBuy/sell laggards

�� Putting on Long/Short positions; hedgingPutting on Long/Short positions; hedging

�� Early warning signals from charts of related stocksEarly warning signals from charts of related stocks

Page 26: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Interpreting Interpreting

Context/EnvironmentContext/Environment

�� More on Environmental Issues:More on Environmental Issues:

�� Do you know how the various sectors have Do you know how the various sectors have

performed? Knowing relative sector performed? Knowing relative sector

performance is very important in trading stocks.performance is very important in trading stocks.

�� Do you know how the stocks you are interested Do you know how the stocks you are interested

in have performed in their sector?in have performed in their sector?

Page 27: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Interpreting Context/EnvironmentInterpreting Context/Environment

Sector performanceSector performance

Page 28: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 29: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Interpreting Interpreting

Context/EnvironmentContext/Environment

�� More on Environmental Issues:More on Environmental Issues:

�� If you wish to trade a stock and hold it for If you wish to trade a stock and hold it for various time frames, do you know how it usually various time frames, do you know how it usually behaves?behaves?

�� One can get to learn a stockOne can get to learn a stock’’s usual behavior by s usual behavior by being glued to its Level II screen being glued to its Level II screen –– how many how many stocks can one monitor like that?stocks can one monitor like that?

�� Alternative : DataAlternative : Data--mining mining –– understand the understand the behavioral characteristics, in terms of the risk behavioral characteristics, in terms of the risk and returns, of the stocks you tradeand returns, of the stocks you trade

Page 30: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Interpreting Context/EnvironmentInterpreting Context/Environment

Individual stock riskIndividual stock risk--return return

Page 31: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Interpreting Interpreting

Context/EnvironmentContext/Environment

�� More on Environmental Issues:More on Environmental Issues:

�� The example shows how MSFT has performed in the The example shows how MSFT has performed in the

last two years, if one were looking at six month time last two years, if one were looking at six month time

frames (assuming holding it for 6 months at a time).frames (assuming holding it for 6 months at a time).

�� The dataThe data--mining shows that the stock has fallen by an mining shows that the stock has fallen by an

amount that is extreme by historical standards, and the amount that is extreme by historical standards, and the

risk is on the upside, not down.risk is on the upside, not down.

�� An astute trader may look for technical signals to buy An astute trader may look for technical signals to buy

than to sell the stock at those levels.than to sell the stock at those levels.

Page 32: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Interpreting RiskInterpreting Risk

�� Interpreting Risk:Interpreting Risk:�� Talking about risk, would it not be prudent for an user Talking about risk, would it not be prudent for an user to be able to identify what risks are associated with any to be able to identify what risks are associated with any stock he or she wants to trade?stock he or she wants to trade?

�� This is done by constructing detailed historical This is done by constructing detailed historical distributions of returns, for every stock, so that this distributions of returns, for every stock, so that this provides a reality check of how risks are handled. provides a reality check of how risks are handled.

�� Such dataSuch data--mining on the risk side is extremely mining on the risk side is extremely important as such information tells one important as such information tells one

what NOT to trade, even before what NOT to trade, even before

technical analysis is applied technical analysis is applied

Page 33: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Interpreting RiskInterpreting Risk

Individual stock risk Individual stock risk

Page 34: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Interpreting RiskInterpreting Risk

Risk of stock inside sector Risk of stock inside sector

Page 35: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Interpreting RiskInterpreting Risk

Risk reports Risk reports

Page 36: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Analytical SupportAnalytical Support

�� Analytical Support:Analytical Support:

�� Many things are possible.Many things are possible.

�� Example: How to improve on ordinary Moving Average Example: How to improve on ordinary Moving Average

Crossover Analysis with dataCrossover Analysis with data--mining:mining:

�� Moving Averages work best in trending markets or at least Moving Averages work best in trending markets or at least

markets which do not show much markets which do not show much ““whipsawwhipsaw”” behaviorbehavior

�� One cannot possibly take a position on every case of moving One cannot possibly take a position on every case of moving

average crossover that appears on oneaverage crossover that appears on one’’s charts or trading s charts or trading

modelsmodels

�� Some preliminary screening will go a long way in eliminating Some preliminary screening will go a long way in eliminating

false leadsfalse leads

Page 37: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Analytical SupportAnalytical Support

Consistency in Performance Consistency in Performance

Page 38: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Analytical SupportAnalytical Support

�� Another ExampleAnother Example

�� For a stock (STAR) that has performed consistently over For a stock (STAR) that has performed consistently over the last 12 months (daily), the application of MA analysis the last 12 months (daily), the application of MA analysis should be fruitfulshould be fruitful

�� Apply a 50 period MA to all time bars smaller than Daily Apply a 50 period MA to all time bars smaller than Daily bars:bars:

�� P/L for MA P/L for Buy and HoldP/L for MA P/L for Buy and Hold

�� 5mb 5mb --$51 $51 --$201$201

�� 10mb +$209 10mb +$209 -- $282$282

�� 15mb +$146 15mb +$146 --$326$326

�� 30mb 30mb -- $59$59 --$295$295

�� 60mb +$20460mb +$204 --$258$258

�� Daily +$853Daily +$853 +$687 +$687

Page 39: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Analytical SupportAnalytical Support

Consistent Performance Consistent Performance

Page 40: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Analytical SupportAnalytical Support

�� Another Example:Another Example:

�� For a stock (TRW) that has performed consistently over the For a stock (TRW) that has performed consistently over the last six months (daily), the application of MA analysis looks last six months (daily), the application of MA analysis looks like this:like this:

�� Apply a 50 period MA to all time bars smaller than Daily Apply a 50 period MA to all time bars smaller than Daily bars (300 bars before 22 Jul 02):bars (300 bars before 22 Jul 02):

�� P/L for MA P/L for Buy and HoldP/L for MA P/L for Buy and Hold

�� 5mb +$263 5mb +$263 --$258$258

�� 10mb +$96 10mb +$96 -- $651$651

�� 15mb +$500 15mb +$500 --$620$620

�� 30mb +$1830mb +$18 --$620$620

�� 60mb +$51360mb +$513 --$494$494

�� Daily +$660Daily +$660 +$607 +$607

Page 41: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Analytical SupportAnalytical Support

�� Summarizing:Summarizing:

�� One tentative conclusion is that by picking stocks that One tentative conclusion is that by picking stocks that

have shown consistent performance in the past (either have shown consistent performance in the past (either

up or down) and monitoring their performance on an up or down) and monitoring their performance on an

ongoing basis, those that remain on a consistent path, ongoing basis, those that remain on a consistent path,

can be screened for trading with very simple tools like can be screened for trading with very simple tools like

Moving Averages.Moving Averages.

�� This is NOT meant to illustrate a specific trading This is NOT meant to illustrate a specific trading

technique, but is only intended to show how datatechnique, but is only intended to show how data--

mining can add value to commonly used technical mining can add value to commonly used technical

analysis. analysis.

Page 42: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Analytical SupportAnalytical Support

Another Another egeg –– Parametric OptimizationParametric Optimization

Page 43: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Analytical SupportAnalytical Support

This logic of using data mining to support technicalThis logic of using data mining to support technical

analysis can be extended to the analysis can be extended to the ““prepre--processingprocessing”” of rawof raw

information, so that we can have betterinformation, so that we can have better

assessments of whether stocks are in a situation to benefitassessments of whether stocks are in a situation to benefit

from the application of traditional technical methods:from the application of traditional technical methods:�� Scanning for breakouts to trade channel breakout or volatility Scanning for breakouts to trade channel breakout or volatility

breakout systems;breakout systems;

�� Scanning for rebounds and dips to trade OscillatorsScanning for rebounds and dips to trade Oscillators

�� Scanning for Volume spikes Scanning for Volume spikes

�� Scanning for Scanning for FibonachiFibonachi levels for support and resistancelevels for support and resistance

�� Scanning for Fundamentals for buying oversold stocksScanning for Fundamentals for buying oversold stocks

�� Scanning for MAE/MFEScanning for MAE/MFE

Page 44: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 45: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– VisualizationVisualization

DataData--Mining is not just about number crunching. ItMining is not just about number crunching. It

is also about better is also about better visualizationvisualization of relationshipsof relationships

�� Put hard numbers into pictorial form, colorful Put hard numbers into pictorial form, colorful pictures and relate difficultpictures and relate difficult--toto--interpret numbers interpret numbers into a coherent whole and patterns may emergeinto a coherent whole and patterns may emerge

�� So, dataSo, data--mining is also about using mining is also about using ““pictures to pictures to paint a thousand numberspaint a thousand numbers””. Turn geek. Turn geek--speak and speak and greekgreek into maps.into maps.

�� This is in fact one of the main objectives and uses This is in fact one of the main objectives and uses of dataof data--mining.mining.

Page 46: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– VisualizationVisualization

�� In In the next slide, we will display a way of the next slide, we will display a way of

visualizing the visualizing the NasdaqNasdaq marketmarket

�� Green for up and red for down stocks, in Green for up and red for down stocks, in

different degrees (shades) of changedifferent degrees (shades) of change

�� Stocks are shown as big, mid and small capsStocks are shown as big, mid and small caps

�� Can be regrouped to portray different Can be regrouped to portray different

aspects of price and volume behavior aspects of price and volume behavior

Page 47: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Visualization Visualization -- HeatMapsHeatMaps

NasdaqNasdaq Market, May 13, 02Market, May 13, 02

Page 48: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Visualization Visualization –– Heat MapsHeat Maps

�� The previous The previous HeatMapHeatMap shows the shows the NasdaqNasdaq market market on May 13on May 13thth 2002, long before the WCOM fraud 2002, long before the WCOM fraud was announced.was announced.

�� On that day, you could see the entire market On that day, you could see the entire market rallying, yet that stock was the biggest bigrallying, yet that stock was the biggest big--cap cap loserloser

�� Seeing the information is such stark contrast, one Seeing the information is such stark contrast, one could assess its relative position in the market and could assess its relative position in the market and maybe some could have been prescient enough to maybe some could have been prescient enough to stay out. Traditional TA might have told you that stay out. Traditional TA might have told you that it was oversold.it was oversold.

Page 49: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Visualization Visualization –– Heat MapsHeat Maps

NasdaqNasdaq Market, Jul 19, 02Market, Jul 19, 02

Page 50: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Visualization Visualization –– Heat MapsHeat Maps

�� That was the That was the HeatMapHeatMap of the of the NasdaqNasdaq on 19 Jul on 19 Jul 02, the day when the DJIA went down by 390 02, the day when the DJIA went down by 390 pts to 8019 (pts to 8019 (--4.6%), seventh largest point loss in 4.6%), seventh largest point loss in history thenhistory then

�� One big cap, AMGN, was up, and there were a One big cap, AMGN, was up, and there were a lot of small caps gaining on the daylot of small caps gaining on the day

�� By seeing information in this form, one could By seeing information in this form, one could keep out of trouble or even capitalize on keep out of trouble or even capitalize on opportunities.opportunities.

Page 51: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining -- VisualizationVisualization

�� Visualization can be done on anything to Visualization can be done on anything to

translate a massive amount of data into translate a massive amount of data into

convenient, easyconvenient, easy--toto--interpret analyticsinterpret analytics

�� One classic area is the very important Time & One classic area is the very important Time &

Sales, which generate price and volume Sales, which generate price and volume

informationinformation

�� We can plot the data into various kinds of Price We can plot the data into various kinds of Price

–– Volume chartsVolume charts

Page 52: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Visualization Visualization –– Price Volume ChartsPrice Volume Charts

PV Chart, EPV Chart, E--bay, Jul 22, 02 bay, Jul 22, 02

Page 53: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 54: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 55: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 56: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 57: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 58: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Developing FocusDeveloping Focus

�� Some examples:Some examples:

�� If you wish to use a particular technical If you wish to use a particular technical

indicator, do you know if it has been successful indicator, do you know if it has been successful

on a stock in the past, or what stocks were good on a stock in the past, or what stocks were good

stocks to trade using that indicator? Or for a stocks to trade using that indicator? Or for a

given stock, what indicators should be used?given stock, what indicators should be used?

�� DataData--mining can shed light on these key mining can shed light on these key

questions, again narrowing our focus to what is questions, again narrowing our focus to what is

most likely to be successfulmost likely to be successful

Page 59: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Developing FocusDeveloping Focus

Best Stock Scan Best Stock Scan

Page 60: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Developing FocusDeveloping Focus

Best Indicator Scan Best Indicator Scan

Page 61: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Developing FocusDeveloping Focus

In indicator analysis, with typical American abundance, In indicator analysis, with typical American abundance, there is a lot of choice. The universe is now more than there is a lot of choice. The universe is now more than a hundred indicators, most of which need to be visually a hundred indicators, most of which need to be visually interpreted. There are all kinds of time bars to analyze. interpreted. There are all kinds of time bars to analyze. Is there too much choice?Is there too much choice?

�� There are many indicators that have specific buyThere are many indicators that have specific buy--sell sell rules. rules. �� Can we apply dataCan we apply data--mining to find out what they ALL say mining to find out what they ALL say about a particular stock at a given time?about a particular stock at a given time?

�� How about what time bar is best for a particular indicator on How about what time bar is best for a particular indicator on a particular stock?a particular stock?

Page 62: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Developing FocusDeveloping Focus

Indicator summary Indicator summary

Page 63: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Developing FocusDeveloping Focus

�� The slide shows how The slide shows how

datadata--mining can be mining can be

applied innovatively to applied innovatively to

create neat summaries create neat summaries

Indicator summary Indicator summary

Page 64: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Developing FocusDeveloping Focus

�� Example 8:Example 8:

�� How about eliminating How about eliminating

some confusion as to some confusion as to

which time bar to use? which time bar to use?

�� Can we find out what has Can we find out what has

worked in the recent past?worked in the recent past?

Time bar analysis Time bar analysis

Page 65: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

DataData--Mining Mining –– Putting it togetherPutting it together

�� DataData--mining can be used on its own, but mining can be used on its own, but

would reinforce the two other major pieces of would reinforce the two other major pieces of

technical market analyses : technical market analyses : BacktestingBacktesting and and

Risk ManagementRisk Management

�� Comprehensive Approach to Technical Comprehensive Approach to Technical

Trading:Trading:

�� Step 1: DataStep 1: Data--MiningMining

�� Step 2: Historical Step 2: Historical BacktestingBacktesting

�� Step 3: Risk ManagementStep 3: Risk Management

Page 66: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

RealReal--time Backtime Back--testing testing

Historical Historical BacktestingBacktesting

Page 67: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

BackBack--testing: Portfolio Diversificationtesting: Portfolio Diversification

Risk Management Risk Management -- trading trading

diversified systems and diversified systems and

using portfoliosusing portfolios

Page 68: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 69: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 70: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt
Page 71: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

It’s the whole

DataData--Mining: Mining: GooglingGoogling the Streaming the Streaming

PricesPrices

�� The Essence of The Essence of AlgoAlgo Trading with an Edge :Trading with an Edge :

Trading with an Edge = Trading with an Edge = prepre--simulation simulation

DataData--Mining + Strategy Mining + Strategy BacktestingBacktesting + + post post simulationsimulation Risk ManagementRisk Management

== !!

Page 72: Algorithmic Google on Streaming Prices _Technical&FundamentalAnalyses + PortfolioMgt

Thank YouThank You

�� Guan Seng Khoo, PhDGuan Seng Khoo, PhD

�� Head, Global Risk (Models Validation)Head, Global Risk (Models Validation)

�� Group Risk AnalyticsGroup Risk Analytics

�� Standard Chartered BankStandard Chartered Bank

�� +65 9825 2148; +65 9825 2148; [email protected]@gmail.com

�� ExEx--AlgoAlgo Trading Developer & Fund Mgr, Trading Developer & Fund Mgr,

�� ManMan--DrapeauDrapeau Group, part of the Man Group, part of the Man Group, 1996Group, 1996--20022002