Click here to Login





                                                   Historical Volatility

  0

0
dare2
2012-09-21 15:00:00


Does anyone know of a formula for HV, historical volatility aka implied volatility. I am interested in being able to screen stocks using a 50 period SMA of HV.

Thanks,
Darrell



clonex
2012-09-21 15:34:14

  0


dare2
2012-09-21 16:32:38

  0

Thanks Clonex.


allan nathan
2012-09-21 16:55:07

  1

Best Answer
try this for functions


VectorD close = cFunctions.Close;
VectorD logchange = TA.Log(close/TA.Ref(close,1));
VectorD sdlogchange = TA.Stddev(logchange,50);
VectorD HisVol = sdlogchange*100*TA.Sqrt(252);
result = HisVol;

OR

//result = cFunctions.CompileFormula("logchange=log(close/Ref(close,1));
//sdlogchange=stddev(logchange,50);
//HisVol=sdlogchange*100*sqrt(252);").
//GetVectorDouble("HisVol");

for formula try this,but change daye=50

Days = Param("Days", 21, 21);
logchange=log(close/Ref(close,1));
sdlogchange=stddev(logchange,21);
HisVol=sdlogchange*100*sqrt(252);
Plot(HisVol,"HVol",colorBlue,ChartLine);



dare2
2012-09-21 17:20:10

  0

Thanks allan.l.


No more messages
0




Reply:

No html code. URLs turn into links automatically.

Type in the trading objects you want to include: - Add Objects
To add a trading object in your message, type in the object name, select it and then click on "Add Objects"










QuantShare

Trading Items
HV - Historical Volatility
VolDex Implied Volatility Index - Historical Data
Implied Volatility of iPath ETNs - IV Historical Data
Historical volatility regimes
Yang Zhang extension of the Garman-Klass Volatility Estimator

How-to Lessons
How to download historical quotes of indices
How to download historical EOD data for penny stocks
How to add trades from one portfolio to another one
How to download EOD quotes for active and valid stocks only
How to import trading data from CSV files

Related Forum Threads
Historical volatility
Historical Fundamentals data, US stocks
Calculate total volatility of portfolio
historical analysis
Today´s quote in Historical view?

Blog Posts
Historical volatility estimators
Forecast volatility using trading rules and neural networks
How to make sure your Historical Price Data is Split Adjusted
Rules performance for different volatility regimes
Download historical EOD data for the stock, futures, ETF and Fore...









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 © 2024 QuantShare.com
Social Media
Follow us on Facebook
Twitter Follow us on Twitter
Google+
Follow us on Google+
RSS Trading Items



Trading financial instruments, including foreign exchange on margin, carries a high level of risk and is not suitable for all investors. The high degree of leverage can work against you as well as for you. Before deciding to invest in financial instruments or foreign exchange you should carefully consider your investment objectives, level of experience, and risk appetite. The possibility exists that you could sustain a loss of some or all of your initial investment and therefore you should not invest money that you cannot afford to lose. You should be aware of all the risks associated with trading and seek advice from an independent financial advisor if you have any doubts.