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

Notification

Icon
Error

Options
Go to last post Go to first unread
nadero  
#1 Posted : Sunday, August 12, 2007 7:50:12 AM(UTC)
nadero

Rank: Newbie

Groups: Registered, Registered Users
Joined: 8/11/2007(UTC)
Posts: 2

Hello, I am a newbie in this forum.

I know the syntax of MetaStock functions and also have some practice with C++ (not a professional one, but as a hobby). Of course I have also experience using MetaStock.

Now, I am learning C# and I would like to practice my new skills with MetaStock, so I need to learn about the metastock files, how to call its functions, etc. Could someone give me some guidelines for the beginning (resources, references, etc.) ?.

Thank you very much (and I wish you good trade :)).

johnl  
#2 Posted : Friday, September 7, 2007 10:47:16 PM(UTC)
johnl

Rank: Advanced Member

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

Do a Google search on "Metastock formula" and you should get a bunch of indicator formulas
to play with.
hxxp://www.metastocktools.com/index.html#tools
hxxp://www.bertigianluca.it/finanza/metastock_formulas/metastock_formulas_index.htm
hxxp://www.brave.net.au/ms/list_indicators.php
are 3 examples.

wabbit  
#3 Posted : Saturday, September 8, 2007 12:04:46 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)
Hi nadero,

Welcome to the Fourm.

nadero wrote:
I know the syntax of MetaStock functions and also have some practice with C++ (not a professional one, but as a hobby). Of course I have also experience using MetaStock.

Now, I am learning C# and I would like to practice my new skills with MetaStock, so I need to learn about the metastock files, how to call its functions, etc. Could someone give me some guidelines for the beginning (resources, references, etc.) ?


You can write functions inside MetaStock using the MetaStock Formula Language; which is a simple programming language designed for TRADERS to add functionality to their charts, exploratons etc. The langauge has a very simple syntax and is virtually unbreakable, but the cost for this simolicity is that it is very limited in its functionality when compared to other programming languages.

To extend beyond the limitations of the MetaStock Formula Langauge you will need the MetaStock Developers Kit which will allow you to write your own custom functions in C/C++, PowerBasic or Delphi Pascal, C# is not supported but some very savvy programmers have found ways around this and have started writing some MS stuff in C#. IF you already have a C++ IDE then stick with this as it it will mean that you can have your functiosn up and running sooner than having to build workaround solutions in C#. In these external functions you can write MSX (MetaStock External functions) or MSFL (MetaStock File Library funtions)(if you can get the MDK Write version, you can create your own MS data records too). One thing you will have to consider is that the internal functions of MetaStock are not available to be called from external functions, so any functionality you want has to be coded from scratch, so the learning curve is steep from the very start.

To start learning about writing MetaStock Formula Language indicators explorations etc, start by reading the MS Uses Manual that came with your version of MetaStock; read it cover to cover a few times, then download the free Equis Formula Primer from the downloads section. Work through the exercises contained therein. All during this phase of your learning, have alook through the indicators, explorations etc that are built-in to your version of MS, some are password protected but the others can be used as examples to demonstrate some of the required principles.

To start learning how to write external functions and library functions, start by purchasing the MDK and then reading the MDK Users Manual a few times and look through the example files very carefully. It wont make much sense at the start (or maybe it will?) but eventually you will get better by practicing writing some simple functions.

If ever you get stuck, you can always post your best attempt of your code here at the Forum, along with a full explanation of what you are trying to achieve and a full explanation of what is going wrong, and any relevant error messages, and I am sure someone will promptly assist.


Hope this helps.

wabbit [:D]

PTJim  
#4 Posted : Sunday, September 9, 2007 2:02:33 PM(UTC)
PTJim

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 5/10/2006(UTC)
Posts: 252

Thanks: 11 times
Was thanked: 9 time(s) in 6 post(s)
wabbit wrote:
One thing you will have to consider is that the internal functions of MetaStock are not available to be called from external functions, so any functionality you want has to be coded from scratch, so the learning curve is steep from the very start.


That strikes me as quite odd . . . you too?

wabbit  
#5 Posted : Sunday, September 9, 2007 6:58:59 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)
PTJim wrote:
wabbit wrote:
One thing you will have to consider is that the internal functions of MetaStock are not available to be called from external functions, so any functionality you want has to be coded from scratch, so the learning curve is steep from the very start.


That strikes me as quite odd . . . you too?


Not really. MetaStock allows the external function to have access to the MS data structure by reference, so now all of the data for the current open chart can be processed externally. To call the MS functions from the external function would mean having to make calls back to MS, then re-receive the data values (for which no structure currently exists) and then the external function would have to send back the results of its own computations to MS for display. If MS formula calls were allowed, I could see the possibility of either crashing MS or seriously corrupting the chart data; so it is much more simple and stable to prevent the coder from having access and forcing them to rewrite the functions themselves.

It doesn't mean the required information cannot be sent to the external call as an argument value; if the exernal code requires the 200 bar EMA, just send this data as part of the external function call.


Hope this helps.

wabbit [:D]

nadero  
#6 Posted : Monday, September 10, 2007 2:51:17 PM(UTC)
nadero

Rank: Newbie

Groups: Registered, Registered Users
Joined: 8/11/2007(UTC)
Posts: 2

Thank you for your kindly answers.

By the way I would like to know in wich files are estored simbols (horizontal lines, vertical lines, fibonacci arcs, etc.) and also to know wich format they have. I would like make my first program to modify those simbols.

Thanks again.

uasish  
#7 Posted : Monday, September 10, 2007 8:28:27 PM(UTC)
uasish

Rank: Advanced Member

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

Thanks: 7 times

Wabbit,

Having no knowledge in computer language ,i would like to get a confirmation from you;

1) TradeSim uses this feature of Mark Pyle's GV / Roy's Equity Curve ?

If so,why then the Back Testing cant be improved in MS.

Asish

Users browsing this topic
Guest (Hidden)
Similar Topics
hello everyone (Formula Assistance)
by dogovinhdinh 1/30/2021 2:23:07 AM(UTC)
hello, i just join here to know more about you all (Formula Assistance)
by Guest 6/13/2019 3:19:12 PM(UTC)
Hello guys (3rd Party Advertisements)
by TheGreg 10/18/2015 2:33:14 PM(UTC)
Hello, Need some help with formulas. (Formula Assistance)
by igarek 7/23/2014 5:33:34 AM(UTC)
Hello (Formula Assistance)
by stocksrsrch 3/26/2013 10:36:01 PM(UTC)
Hello everybody, a special trailing stop problem (Formula Assistance)
by itourei 7/28/2009 1:26:19 PM(UTC)
hello everyone! (Forum Feedback)
by george112 7/14/2009 5:54:08 AM(UTC)
Hello to Everyone (Charts with Lightning Strikes system) (3rd Party Advertisements)
by rbwyrw 10/20/2007 7:32:34 AM(UTC)
hello Like putting the lunar phases in Meta Gracias (Formula Assistance)
by frapas59 12/20/2006 7:04:01 AM(UTC)
Hello everyone (General Chat)
by Benny 3/28/2006 9:04:02 AM(UTC)
Hello World! (MetaStock Developer's Kit (MDK) Assistance)
by Ricci 11/29/2005 5:23:12 PM(UTC)
Say hello to Grant! (Product Wish List)
by StorkBite 10/26/2005 7:32:35 PM(UTC)
hello iam from saudi arabi (General Chat)
by newo900 10/19/2005 6:16:23 AM(UTC)
Hello, anyone from Greece ? (User Groups)
by pantits 8/19/2005 1:10:02 PM(UTC)
Hello forum (Plugins & Addons)
by 12noon 6/22/2005 9:46:05 PM(UTC)
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.