Limiting scope of the study

Studies that have been contributed to the community by other users. If you’ve got something useful to share, that’s great!
XIKON
Posts: 23
Joined: 15 Dec 2010
Has thanked: 3 times
Been thanked: 3 times

Limiting scope of the study

Postby XIKON » 15 Dec 2010

Hi Everyone,

Just joined the discussion forum and a new user of MC. I have been fiddling with some of the scripts in order to limit the scope of the studies, for example to carry out the study from 2001 onwards. Unfortunately it does not seem to be responding to the changes I am making. Is there anyone who could kindly advise how I need to edit any script so that it will only study the timeframe of 2001 - 2010. This is particularly important as I am studying the performance of a few indicators from 2001-2010 and the strategy performance report has to be based on this timeframe. I can artificially change this by setting the maximum number of bars study will reference however I will have to go through 350 or so securities in order to change the maximum number of bars individually.

I would much appreciate your assistance.

Many thanks.

XIKON

User avatar
TJ
Posts: 7740
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2221 times

Re: Limiting scope of the study

Postby TJ » 15 Dec 2010

Hi Everyone,

Just joined the discussion forum and a new user of MC. I have been fiddling with some of the scripts in order to limit the scope of the studies, for example to carry out the study from 2001 onwards. Unfortunately it does not seem to be responding to the changes I am making. Is there anyone who could kindly advise how I need to edit any script so that it will only study the timeframe of 2001 - 2010. This is particularly important as I am studying the performance of a few indicators from 2001-2010 and the strategy performance report has to be based on this timeframe. I can artificially change this by setting the maximum number of bars study will reference however I will have to go through 350 or so securities in order to change the maximum number of bars individually.

I would much appreciate your assistance.

Many thanks.

XIKON
there are 2 ways to do it:

1. load only the bars you want into the chart.

2. modify your script:

eg.

Code: Select all

if date > 1010101 then
begin
{-- put your code here --}
end;

XIKON
Posts: 23
Joined: 15 Dec 2010
Has thanked: 3 times
Been thanked: 3 times

Re: Limiting scope of the study

Postby XIKON » 17 Dec 2010

TJ,

Thanks a lot. I did try the first option but it meant that everytime I had to change the settings. I tried the script as well but I was typing ELDATE instead of DATE and therefore was not getting the result I was looking for.

Thanks a lot, everything seems working now. It is much appreciated.

Regards,

XIKON

User avatar
TJ
Posts: 7740
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2221 times

Re: Limiting scope of the study

Postby TJ » 17 Dec 2010

TJ,

Thanks a lot. I did try the first option but it meant that everytime I had to change the settings. I tried the script as well but I was typing ELDATE instead of DATE and therefore was not getting the result I was looking for.

Thanks a lot, everything seems working now. It is much appreciated.

Regards,

XIKON

you are welcome


Return to “User Contributed Studies and Indicator Library”