Rank: Newbie
Groups: Registered, Registered Users Joined: 7/26/2005(UTC) Posts: 3
|
Is it possible to code this: volume increase 50% and price is closed at 52 week high?
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users Joined: 3/19/2005(UTC) Posts: 2,995
Was thanked: 14 time(s) in 10 post(s)
|
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users Joined: 6/13/2005(UTC) Posts: 52
|
If I understand you correctly, you are looking for the close today to be the highest close for the last 52 weeks.
If so, here is one scenario:
C>Ref(HHV(C,252),-1)
If you are looking for highs then substitute the letter H (High) for the C (Close).
It should be noted that in any calendar year there are approximately 252+ trading days
Now let look at the volume part of your question. When looking for a volume surge, in your case 50%, it is usually based upon the % over an average volume for a specific number or days. Let say 20 days then one scenario is as follows:
V>Mov(V,20,S)*1.5
It can also be written where today’s data is not included in the average volume as follows:
V>Ref(Mov(V,20,S).-1)*1.5 Note: In this case you are really looking at data over the last 21 days.
Good luck investing
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users Joined: 3/19/2005(UTC) Posts: 2,995
Was thanked: 14 time(s) in 10 post(s)
|
Thanks IR for coming to the rescue! I knew I was going to be a bit off, but gave it a shot! :D So, changed it up a little, I'd have been on target.
H=Ref(HHV(H,252),-1) AND V>Ref(V,-1)*1.5;
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 9/8/2004(UTC) Posts: 2,266
Was thanked: 1 time(s) in 1 post(s)
|
Thumbs up to G who wrote is very first forum Formula :smt023
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users Joined: 4/21/2005(UTC) Posts: 33
|
let's say we use the above formula as our buy condition. How would we code it to sell in the system tester based on number of days, perhaps 10 days after this buy situation occurred? I am familiar with the ref function but will system tester know that you are referencing your buy situation?
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers, Unverified Users Joined: 10/28/2004(UTC) Posts: 3,111 Location: Perth, Western Australia
Was thanked: 16 time(s) in 16 post(s)
|
This is where the barssince() function comes in.....
wabbit :D
|
|
|
|
Users browsing this topic |
Guest (Hidden)
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.