Filter Entry Criteria Based on Average Volume
Author: traindl
Creation Date: 5/25/2012 5:01 AM
profile picture

traindl

#1
Hello,

i just wanted to know how i can write a programm code to install a filter for my entry criteria for portfolio simulation.
for example my entry criteria is to buy at market bar+1 if stochastik %D is < 20
and now i would like to add a filter: only take those equities where volume at signal bar is smaller at least 10% then average volume (sma volume of the last 10 days)

can somebody help me to create this code and at which line this code should stand?

would be great !!

thanks
thomas
profile picture

Eugene

#2
Welcome to the forums Thomas,
QUOTE:
and now i would like to add a filter: only take those equities where volume at signal bar is smaller at least 10% then average volume (sma volume of the last 10 days)

Here you go:
CODE:
Please log in to see this code.


Actually, you don't even have to code this. Take Position Options from our MS123 PosSizer library, and set it up like this:



profile picture

traindl

#3
Hello Eugene

thanks for quick information .. i will try this :)

This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).