[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[amibroker] Re: Vectorvest



PureBytes Links

Trading Reference Links

I think you are getting close.  
Item: For BP I used (O+H+L+C)/4 for each bar - it provides some additional smoothing - since you are using more data to determine price.
Item: In my Kalman filter I made the sqrt function into a variable**.  The idea was that taking something to a power less than one decreases the dynamic range of the variable and thus its smoothing effect.  (If var=2 goes to var=4 you get a times 2.  If you take the square root (0.5 power) it is only 1 : 1.4.  On the other hand if you raise it to a power - say 3 then a double 2 to 4 increases the dynamic range 8 to 64 or 1 : 8.)

This trick allows you to control the dynamic range of the amount of smoothing you want to use in the filter.

ReefBreak

 
** this is how to make the exponent into a variable:
x = some function;
y = arg ^ x;  /any function to any power;

Say where x can take on values from 0.3 to 3.0.  So you can control the amount of influence y will have in the Kalman smoothing function.

Regarding the R library.  The Kalman method allows you to incorporate the elements YOU think are important in smoothing the price.  This general nature of the method accounts for Kalman's popularity.  It is used in everything from positioning disk drive heads to guiding heat seeking missiles to flying unmanned planes and helicopters.

--- In amibroker@xxxxxxxxxxxxxxx, "LongJack" <loveyourenemynow@xxx> wrote:
>
> I think R has built in extensive time series analysis functions, and also Kalman filter.
> There is a plugin you use, or the com server and create a static object.
> 
> Regards
> Ly
> 
> --- In amibroker@xxxxxxxxxxxxxxx, Rick Osborn <ricko@> wrote:
> >
> > 
> > out of curiosity, how close is this which I cobbled together based on my (limited) understanding of the dense math?
> > 
> > Gain = Param("Gain",500,5,2000,5);
> > BP = C;
> > Pred = 0;
> > Velo = 0;
> > function Kalman ( BP, gain )
> > {
> >     for ( i = 1; i < BarCount; i++ )
> >     {
> >         Dk[i] = BP[i] - Pred[i-1];  // Delta k
> >         Smooth[i] = Pred[i-1] + DK[i] * sqrt( ( Gain / 10000 ) * 2 );
> >         Velo[i] = Velo[i-1] + ( ( Gain / 10000 ) * Dk[i] );
> >         Pred[i] = Smooth[i] + Velo[i];
> >         kf[i] = Pred[i];
> >     }
> > 
> >     return kf ;
> > 
> > }
> > 
> > 
> > 
> > 
> > 
> > ________________________________
> > From: reefbreak_sd <reefbreak_sd@>
> > To: amibroker@xxxxxxxxxxxxxxx
> > Sent: Monday, September 7, 2009 10:50:00 AM
> > Subject: [amibroker] Re: Vectorvest
> > 
> >    
> > The .afl formulas for T3 that I can find are not Kalman style filters.  The one I created uses the AMA2 function built into AB. 
> > 
> > There are many references to Kalman on the internet.  For stock trading I chose one dimension and linear combination of functions.  A good place to start is the Wikipedia article.  Yes the math is a little dense, but some of the articles have enough verbal description that you can sort it out - at least that is how I did it.
> > 
> > ReefBreak
> > 
> > --- In amibroker@xxxxxxxxx ps.com, Rick Osborn <ricko@> wrote:
> > >
> > > would you consider the Tilson T3 function to be a Kalman Filter?
> > > 
> > > 
> > > 
> > > 
> > > 
> > > 
> > > 
> > > ____________ _________ _________ __
> > > From: reefbreak_sd <reefbreak_sd@ ...>
> > > To: amibroker@xxxxxxxxx ps.com
> > > Sent: Friday, September 4, 2009 10:39:13 AM
> > > Subject: [amibroker] Re: Vectorvest
> > > 
> > > 
> > > Since I made the indicators, I can run them on what ever index I want - rather than on just the VVC.  So I run them on the components of several ETFs that I trade. 
> > > 
> > > For market timing, I have a statistical indicator that uses a Kalman Filter, and one that calculates temperature based on the Boltzman distribution from statistical thermodynamics. In this indicator, the temp goes negative during market declines - unlike what happens in nature.
> > > 
> > > So the total is  about 6 in all.
> > > 
> > > I'm a trend follower.  None of these predicts anything, just accurately reflects the markets current condition.
> > > 
> > > ReefBreak
> > > 
> > > --- In amibroker@xxxxxxxxx ps.com, "donald_brown_ 48367" <donald_brown_ 48367@ > wrote:
> > > >
> > > > I got pretty close with most signals using simple moving average trending.  I also stopped my subscription.  What other indictars do you use?
> > > > 
> > > > --- In amibroker@xxxxxxxxx ps.com, "reefbreak_sd" <reefbreak_sd@ > wrote:
> > > > >
> > > > > Yes, I have written several indicators in .afl that simulate MTI, BSR, Confirmed buy/sell indicators in VV.  They work well enough that I have dropped my subscription to VV.  They are proprietary, not for sale or publication.
> > > > > 
> > > > > ReefBreak
> > > > > 
> > > > > --- In amibroker@xxxxxxxxx ps.com, "donald_brown_ 48367" <donald_brown_ 48367@> wrote:
> > > > > >
> > > > > > I'm curious if anyone has written code to simulate the Vectorvest overall market timing buy and sell signals?
> > > > > >
> > > > >
> > > >
> > >
> >
>




------------------------------------

**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to 
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/amibroker/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/amibroker/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:amibroker-digest@xxxxxxxxxxxxxxx 
    mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx

<*> To unsubscribe from this group, send an email to:
    amibroker-unsubscribe@xxxxxxxxxxxxxxx

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/