log in     sign up for free
 
Dramatic and emotional trading experiences tend to be negative. Pride is a great banana peel, as are hope, fear, and greed. My biggest slip-ups occurred shortly after I got emotionally involved with positions.
Ed Seykota
 
 
Home
systems (284)
 
Special offer: buy MetaStock (try for free)   |   Reuters QuoteCenter Real-Time Data (get a free month)   |   EOD Data
 

Buy

MetaStock

     (special offer)
 
 
 

Buy

EOD data for MetaStock

     (special offer)
 
 
 

Buy

Realtime data for MetaStock

     (special offer)
 
 
 
Formula Library
 
AmiBroker
MetaTrader
MetaStock
TradeStation
Wealth-Lab
NinjaTrader
 
add your formula
System Library
 
 
Account login
Your email:
Password:
 
Log in
New to s4t? Sign up.
If you forgot your password click here.
Search the Web
 
Custom Search

Ulcer Index

Formula for: MetaStock

indicator


 

 

Views:  2400

Added: May 18, 2008
 
Rate this code:  Rate: 1 Rate: 2 Rate: 3 Rate: 4 Rate: 5
This formula has not been rated yet
 

email this link

 
 
Tags: MetaStock, indicator
 
Your Ad Here
From: christie1969us
To: equismetastock[at]yahoogroups.com
Date: Saturday, April 2, 2005, 8:56:03 PM
Subject: [EquisMetaStock Group] Ulcer Index
I have heard of the ulcer index. As I understand it, the problem with Beta is that it measures volatility to both the upside and downside.
We do not mind volatility to the upside.

Is this what the ulcer index is and how is it coded?

Christie

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

From: deepfoobar
To: equismetastock[at]yahoogroups.com
Date: Sunday, April 3, 2005, 3:30:59 AM
Subject: [EquisMetaStock Group] Re: Ulcer Index


I had this laying around but in truth have never used it.



Ulcer Index

Period:=10;
{set this to the number of periods to calculate in the formula}

Sqrt(Sum(Power(100*( HHV(CLOSE,Period) - CLOSE ) /
(HHV(CLOSE,Period)),2),Period)/Period)







There is a description here of what it is meant to do.

http://www.investopedia.com/articles/technical/03/030403.asp

Quotation (from this site):

Developed by Peter G. Martin and Byron B. McCann and described in detail in their book, "The Investor's Guide To Fidelity Funds" (1989), the ulcer index is a very effective risk indicator. Risk means many things to many people but it is inherent to investing.

Peter Martin and Byron McCann, once stated, "the higher an investment's ulcer index, the more likely investing in it will cause ulcers or sleepless nights."

Here's what Gary Elsner, Ph.D., the editor of the mutual-fund timing newsletter Achieve Profits writes:

"The standard deviation is a good measure of volatility, since it measures the amount of variation around the average and is probably the most widely used measure of financial risk. But the standard deviation has two weaknesses for financial instruments. First, it measures the variation from the average in both the up (good) direction as well as the down (bad) direction. Second, the standard deviation does not distinguish between short or long sequences of losses. Investors are only concerned about downside risk (or the potential for losses), whereas upside changes or rapid increases in value create profits. In contrast to the standard deviation, the ulcer index has none of the aforementioned weaknesses since it calculates retracement, the tendency for values to fall from previous highs, by measuring the depth of the drop and the time that it takes the performance measure to recover to the original level."

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

From: christie1969us
To: equismetastock[at]yahoogroups.com
Date: Sunday, April 3, 2005, 7:06:23 AM
Subject: [EquisMetaStock Group] Re: Ulcer Index

This is interesting. From reading the article there seems to be a time element as well. A security being low for 2 days would have a higher ulcer index than just 1 day.

Christie

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

From: MG Ferreira
To: equismetastock[at]yahoogroups.com
Date: Monday, April 4, 2005, 8:02:26 AM
Subject: [EquisMetaStock Group] Re: Ulcer Index

Hi Christie,

There is a very popular model called the GARCH model. It is used to estimate volatility and has shown great potential, even in trading models, and is used a lot nowadays (it was developed in the 80s). You also get many flavours of 'asymmetric' GARCH models, which you may be interested in. If you fit a good asymmetric GARCH model to a ticker,
you can use the model to construct the NIC or news impact curve. This measures, for a piece of 'good' and a similar piece of 'bad' news, the impact it will have on volatility. So you can see how much volatility will increase due to a shock on the downside vs a similar shock on the upside. Have a look at

http://www.ferra4models.com/Shop.html

(which is still under construction) where there are a few NICs to get an idea of what it does. This from an article published in Risk magazine some time ago, if you have access to it, I'll give you the details to get it. This is a very useful device and used by option traders and risk managers, but also quite complex. If it is what you are looking for, just read up a bit on it and feel free to ask!

Regards
MG Ferreira
TsaTsa EOD Programmer and trading model builder
http://www.ferra4models.com
http://fun.ferra4models.com

 

 



Code:

Ulcer Index

Period:=10;
{set this to the number of periods to calculate in the formula}

Sqrt(Sum(Power(100*( HHV(CLOSE,Period) - CLOSE ) /
(HHV(CLOSE,Period)),2),Period)/Period)

 






Author: Peter G. Martin and Byron B. McCann
Source: EquisMetaStock[at]yahoogroups[dot]com

 

View similar (indicator for MetaStock):

Stochastic Relative Strength Index
Weekly Timing Code
OBV - Good Example of if() Function
Signal Count Within Date Period
Williams %R Modified
Accumulation / Distribution - Special
Semi-Intelligent Oscillator - CCT
Pivot Price Indicator
Candle - Harami - Bearish
N BARS
...
 
 
all formulas for MetaStock
all formulas

 

 

Email to friend

Top

 

     
However we try to maintain hiqhest possible level of service - most formulas, oscillators, indicators
and systems are submitted by anonymous users.
Therefore S4T™ does not take any responsibility for it's quality.
If you use any of this information, use it at your own risk. You are responsible for your own trading decisions.
Be sure to verify that any information you see on these pages is correct, and is applicable to your particular trade.
In no case will S4T™ be responsible for your trading gains or losses.
 
Privacy note | (c) copyrights systems4trading.com 2006-2012