Click here to Login








Word Occurrence in News Titles - Quantitative Trading Analysis

by The trader, 720 days ago
Share |








"GetField" is a function that gets a word among a list of words given an index provided as parameter to the function.
The function is mainly used in quantitative trading to optimize News driven trading systems and it works as follows:


// Basic Quantitative System Example

Optimize("i", 0, 7, 1);
a = GetField("buy;sell;up;down;increase;decrease;good;bad", i);
buy = ContainsWords("yahoo_news", "title", a);

This example uses a custom function "ContainsWords" (News parser function).
When optimizing a trading system, the variable "i" will vary from 0 to 7 (There are eight words to analyze). Each time, the "GetField" function returns a different value to variable "a".
If i=0 then "a" will be equal to "buy"
If i=1 then "a" will be equal to "sell"
This function gets a list of words separated by semicolons and then uses the index parameter to return the appropriate word.

The last buy rule consists of analyzing each stock news data and then returning a signal if the word assigned to the variable "a" is found.
In summary, the above strategy buys a stock each time a news title contains a specific word (buy,sell,up,down...)

This is it for the basic example. More advanced quantitative research and analysis can be performed using the "GetField" and "ContainsWords" functions. For example, you can instruct your trading system to generate signals when a combination of words is found.

A quick code sample:

Optimize("i1", 0, 7, 1);
Optimize("i2", 0, 7, 1);
a1 = GetField("buy;sell;up;down;increase;decrease;good;bad", i1);
a2 = GetField("buy;sell;up;down;increase;decrease;good;bad", i2);
buy = ContainsWords("yahoo_news", "title", a1) and ContainsWords("yahoo_news", "title", a2);

Both examples I presented here use news data from Yahoo. This data can be downloaded using the following trading item: Yahoo News.
Other news downloaders, such as Google news (Historical Stock Market News), StockTwits... can also be used.


Share This ->
Share |


You have to log in to bookmark this object
What is this?
Additional Information




Type: Trading Indicator

Object ID: 981


Country:
All

Market: All

Style:
Technical Analysis

Reviews
You must log in first

Join now
and get instant access for free to the trading software, the Sharing server and the Social network website.
Click here


Related objects
Show All
Slope of Support and Resistance Lines (by QuantShare, uploaded several months ago)
No notes

Rate an item Rate an item Rate an item Rate an item Rate an item Number of downloads 7 Notes Report an item
Ichimoku Kinko Hyo - Trading Indicator (by QuantShare, uploaded several months ago)
No notes

Rate an item Rate an item Rate an item Rate an item Rate an item Number of downloads 47 Notes Report an item
Relative Performance/Return Chart - Compare Several Assets/Stocks (by QuantShare, uploaded several months ago)
No notes

Rate an item Rate an item Rate an item Rate an item Rate an item Number of downloads 41 Notes Report an item
Swing Trading Indicator (STI) (by SystemTra.de, uploaded several months ago)
No notes

Rate an item Rate an item Rate an item Rate an item Rate an item Number of downloads 20 Notes Report an item
Swing Point Function (SP) (by SystemTra.de, uploaded several months ago)
No notes

Rate an item Rate an item Rate an item Rate an item Rate an item Number of downloads 30 Notes Report an item
Plot Economic Indicators on a Chart (by QuantShare, uploaded several months ago)
No notes

Rate an item Rate an item Rate an item Rate an item Rate an item Number of downloads 5 Notes Report an item
Mahesh Moving Average (by QuantShare, uploaded several months ago)
No notes

Rate an item Rate an item Rate an item Rate an item Rate an item Number of downloads 88 Notes Report an item
Number of reviews
Click to add a review
Average rate
Click to rate this item
Number of times this object was downloaded
Number of rates the current object received
Report an object
if you can't run it for example or if it contains errors
Click to report this object

Technical Analysis


Fundamental Analysis



Random Blog Posts

Select the best ETFs combination to maximize your return and reduce your investment risk

How to turn any ordinary trading strategy into a very profitable one

Charting & Scripts - Manage stock charts using the global script

Trading System: Buy Stocks based on their Sharpe Ratio Rank

Creating and managing notes for your stocks

Create a Trading Strategy using Portfolio123 Ranking Systems

How to Quickly Create Fundamental Scans

Download Trading Data using the Post-Script

Show All

Number of reviews
Click to add a review
Average rate
Click to rate this item
Number of times this object was downloaded
Number of rates the current object received
Report an object
if you can't run it for example or if it contains errors
Click to report this object






QuantShare
Product
QuantShare
Features
Create an account
Affiliate Program
Support
Contact Us
Trading Forum
How-to Lessons
Manual
Company
About Us
Privacy
Terms of Use

Copyright © 2012 QuantShare.com
Social Media
Follow us on Facebook
Twitter Follow us on Twitter
Google+
Follow us on Google+
RSS Trading Items