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

Notification

Icon
Error

Options
Go to last post Go to first unread
dieselpr  
#1 Posted : Sunday, July 16, 2006 3:39:51 AM(UTC)
dieselpr

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 4/27/2005(UTC)
Posts: 130

Hey, Has anyone coded a formule that would find the top 3 highs during a trading session if the trading session was Month()<>Ref(Month(),-1);?
hayseed  
#2 Posted : Sunday, July 16, 2006 4:36:59 PM(UTC)
hayseed

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 3/7/2005(UTC)
Posts: 1,346

hey diesel.... just filled up 2 allis chalmers dozers , a dump truck and a trac [censored].... what ya reckon thats gonna set me back..... was waitin for some of the better coders to answer first, they must be at the beach.... here's a thought on your quest.... i included both plots, the current one and the offset one, days back so to see the days back plot just shifts forward .... its really reflecting the old data.......... you didn't define 'a trading session' other than 'Month()<>Ref(Month(),-1);' so not sure it that's what was on your mind..... h [code:1:66b2a54caa]perchange:=Input("% peak change",.01,100,1); pds:=Input("days ago",1,200,20); plot:=Peak(1 ,H,perchange); plot; {the true non shifted plot} Ref(plot ,-pds ); {the forward shifted peaks of selected days ago}[/code:1:66b2a54caa]
Jose  
#3 Posted : Sunday, July 16, 2006 5:16:02 PM(UTC)
Jose

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 1/19/2005(UTC)
Posts: 1,065
Location: Koh Pha-Ngan, Earth

Was thanked: 2 time(s) in 2 post(s)
[size=5:e2e909dd70]My guess is a $300~$600 fill-up...[/size:e2e909dd70] You could also try adapting this formula from MetaStockTools.com: "Nth Hi/Lo - plots 1~8th highest/lowest indicator values". jose '-)
dieselpr  
#4 Posted : Sunday, July 16, 2006 6:22:22 PM(UTC)
dieselpr

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 4/27/2005(UTC)
Posts: 130

Thanks Hayseed & Jose, This provides me a direction I guess I should have included a chart with my question. Hayseed- I'm a design engineer I only design trucks & chassis I couldn't tell you how much it would cost to haul thing away. :? Here what I was tring to design for in metastock. I wanted to get the value of the 3rd highest high in the last session mark on this chart by the blue line.
hayseed  
#5 Posted : Monday, July 17, 2006 12:41:46 AM(UTC)
hayseed

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 3/7/2005(UTC)
Posts: 1,346

hey diesel.... jose's subtle hint at the diminishing purchasing power of the dollar was easier to see than your code is to figure out.... still trying... here is something that allows for a start date... it appears a 'session' must be a monthly thing, not familiar with the term used in that manner myself....... jose must have been using 2001 dollars, today it takes about 600 hundred bucks per fill up.... thats off road diesel so its a tad cheaper...... h [code:1:a2d06d6298]M:=Input("month",1,12,6); D:=Input("day",1,31,1); Y:=Input("year",1990,2010,2006); a:=Month()=M AND DayOfMonth()=D AND Year()=Y; HighestSince( 1, a, H);[/code:1:a2d06d6298]
dieselpr  
#6 Posted : Monday, July 17, 2006 3:00:26 AM(UTC)
dieselpr

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 4/27/2005(UTC)
Posts: 130

:D I know what your saying Hayseed. I've been up working on it for the last 2 weeks with nothing close to what I'm looking for. Thanks for tring thou I didn't figure it was going to be to easy to complete. The code you posted didn't return anything on the chart. Was it a direction code?
hayseed  
#7 Posted : Monday, July 17, 2006 3:37:45 AM(UTC)
hayseed

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 3/7/2005(UTC)
Posts: 1,346

hey diesel.... it should plot progressively higher highs from the date selected..... the thought was to visually check the 3rd high......h UserPostedImage
wabbit  
#8 Posted : Monday, July 17, 2006 3:59:04 AM(UTC)
wabbit

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)
dieselpr, h et. al. Do you want to retrospectively indicate the 3rd highest for the month, or dynamically? wabbit :D
dieselpr  
#9 Posted : Monday, July 17, 2006 4:54:51 PM(UTC)
dieselpr

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 4/27/2005(UTC)
Posts: 130

hayseed, I'll take another look at it when I get home tonight thanks. Hi Wabbit, My idea was to find the 3rd highest in the past month to be ref. in the current month. So yes retrospectively. Now there a big word "retrospectively" :lol: Thanks guy for the help
wabbit  
#10 Posted : Monday, July 17, 2006 11:57:28 PM(UTC)
wabbit

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)
I am not sure where it went (you'll have to search the forum (i dont have time right now)), but this is very similar to the challenge that Jose threw open in the first programming competition.... To retrospectively indicate the monthly high and low. We got the code down to just a few lines... Instead of looing for the H and L, look for the 3rd H and 3rd L as Jose has already pointed out in an earlier post in this thread. Combine the two codes and there is your answer. wabbit :D
uasish  
#11 Posted : Thursday, December 28, 2006 8:05:42 AM(UTC)
uasish

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 8/13/2005(UTC)
Posts: 170

Thanks: 7 times

Dieselpr,

Did you found the method ? I want the 3rd Low/High of say Mov(c,3,e)- Mov(c,8,e) as 1 or 0.

Asish

dieselpr  
#12 Posted : Thursday, December 28, 2006 12:28:39 PM(UTC)
dieselpr

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 4/27/2005(UTC)
Posts: 130

Hey uasish is not online. Last active: 12/28/2006, 8:06 Uasish,

I never could find a solution that i was happy with on this idea so to answer your question no I never found it. I purchased the Dev Kit from Equis and am working on some DLL so I might have an answer to this problem later on down the line. Sorry wish I could help.

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.