logo
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
cegorj  
#1 Posted : Wednesday, November 25, 2009 6:19:30 PM(UTC)
cegorj

Rank: Newbie

Groups: Registered, Registered Users
Joined: 11/25/2009(UTC)
Posts: 4

when i use peak fuction, metastock returns the nth previous peak. But this peak can be bellow todays price. What should i do to metastock returns just peaks above current price?
johnl  
#2 Posted : Wednesday, November 25, 2009 7:38:11 PM(UTC)
johnl

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 11/7/2005(UTC)
Posts: 602


Can you compare it to the current price in a If() statement?



cegorj  
#3 Posted : Wednesday, November 25, 2009 11:14:54 PM(UTC)
cegorj

Rank: Newbie

Groups: Registered, Registered Users
Joined: 11/25/2009(UTC)
Posts: 4

I am trying to create an exploration that shows the fisrt and second peak higher than the current price. The fisrt is very easy. Just use the peak fuction. But the second i am not able to get using this, because if i use the peak fuction like this:

peak(2, H, 1) this peak can be lower than the current price. But i want the second peak higher than than the current price. What should i do to create this exploration?

oztrader  
#4 Posted : Thursday, November 26, 2009 3:47:14 AM(UTC)
oztrader

Rank: Advanced Member

Groups: Registered, Registered Users, Unverified Users
Joined: 7/12/2007(UTC)
Posts: 134
Location: Perth Western Australia

"I am trying to create an exploration that shows the fisrt and second peak higher than the current price."

a) Assign values to the variables:-

A = 1st Peak
B = 2nd Peak
C = Current Price

b) Restate your exploration using the values assigned to the variables:-

A > C AND B > C

OR

C < A AND C < B

c) Replace the variables with the correct MetaStock code:-

A = Your Code for A
B = Your Code for B
C = Your Code for C

Try this method and see what you come up with!

If you still have problems then post your code so someone can help out further.

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.