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

Notification

Icon
Error

Options
Go to last post Go to first unread
pinkpanther  
#1 Posted : Tuesday, April 7, 2009 12:03:49 PM(UTC)
pinkpanther

Rank: Newbie

Groups: Registered, Registered Users
Joined: 4/7/2009(UTC)
Posts: 3

Hi
I don't know anything about programming or how to create a indicator/explorer, but this is what I'm looking for:
I would like to write RSI Explorer as following:
How many times is RSI indicator reached (Touched) 90% on the last day?
I use Intraday Data (Tick-1 minute)
RSI=14

Could you please help me to write the explorer?

Thanx

wabbit  
#2 Posted : Tuesday, April 7, 2009 7:41:47 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)
Hi pinkpanther,

Welcome to the forum.

The first place to start learning about MS formula codes is the MS Users Manual. Have a read of it a couple of times because it contains too much information to be fully absorbed on only one reading. In there you will find the rules and syntax for writing codes with some friendly reminders about how not to achieve certain things, and some examples of how to recreate some of the inbuilt indicators in your own code.

From there, the next step is to do all the exercises in the free Equis Formula Primer, available for download from the Files section. This teaches more of the basics on which everything else relies.

You also have all of the indicators that come pre-loaded in MS. Some of these are proprietary and are password protected, but most of them are not. You can use these codes as more examples for writing indicators, system tests, explorations and experts.

Like always, if you get stuck, help is available here on the Forum. Just post your best attempt at the code along with a full explanation of what you are trying to achieve and an explanation why your code is not achieving this and one of the Forum members will give some of their time to help you.

As you will be combining timeframes, intraday and daily, you might want to have a look at Roy Larsen's excellent series of codes at his website: http://www.metastocktips.co.nz/
pinkpanther  
#3 Posted : Wednesday, April 8, 2009 12:32:00 PM(UTC)
pinkpanther

Rank: Newbie

Groups: Registered, Registered Users
Joined: 4/7/2009(UTC)
Posts: 3

Hi wabbit

Thanks for your replay and your advice.

My English isn't very good to learn writing explorer

so could you please help me write the explorer

Thanks
wabbit  
#4 Posted : Wednesday, April 8, 2009 6:45:04 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)
wabbit wrote:
Like always, if you get stuck, help is available here on the Forum. Just post your best attempt at the code along with a full explanation of what you are trying to achieve and an explanation why your code is not achieving this and one of the Forum members will give some of their time to help you.
pinkpanther  
#5 Posted : Thursday, April 9, 2009 2:09:28 PM(UTC)
pinkpanther

Rank: Newbie

Groups: Registered, Registered Users
Joined: 4/7/2009(UTC)
Posts: 3

Hi wabbit

Thanks for your replay

I tried to write but doesn't work

====
If RSI => 90 , 1 , 0
====

but i want the code check all the day time from 9:00AM to 3:00PM and give me how many times RSI touched 90% or above 90%

and i don't know if is it possible to write the code as RSI explorer Metastock or not

Thanks

johnl  
#6 Posted : Thursday, April 9, 2009 9:28:14 PM(UTC)
johnl

Rank: Advanced Member

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

Here is a count of RSI hitting 60 in 2008:
Should give you an idea of where to start.

a1:=Cross(RSI(14),60);
a2:=Year()=2008;
a3:=Cum(a1*a2);
LastValue(a3)
wabbit  
#7 Posted : Thursday, April 9, 2009 10:03:40 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)
Hi pp,

Had you actually read the Users Manual and done the exercises in the Primer, you'd know:

"=>" is not the correct syntax for "greater than or equal to"
That is not the correct syntax for an If() statement
You don't need to assign 1 and zero values to TRUE and FALSE as MS already does this Boolean logic for you

You have also failed any attempt to incorporate time encapsulation into your "code".

The purpose of this forum is to ASSIST you to learn to write your own codes and learn how to use MetaStock. John has kindly given you his time and some of his code; perhaps you should take some components of his code and the other suggestions already made and have another go at writing this for yourself, as an indicator or an exploration, or both.



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.