Some months yes others no

Viewing 15 posts - 1 through 15 (of 16 total)
  • Author
    Posts
  • #6643 quote
    air
    Participant
    Average

    Good day,

    Congratulation for the helpful website. I have been using a monthly system to calculate in which month a certain market performs better than others. However, for currencies, tests are performed on the whole historical data for some months. For other months, nevertheless, just a few months are taken into consideration, without me changing anything. Why?

    Thank you for your help.

    air

    #6647 quote
    Nicolas
    Keymaster
    Master

    Hello air,

    Thanks for your congrats.

    Well, how do you make your calculation? Is is a screener or an indicator? Sorry, but without reading the code, it is very difficult to help you, because I have no idea what’s wrong with your system.. 🙁

    #6652 quote
    air
    Participant
    Average

    Sorry, here is it. For USD/JPY get Dec to March, Dec to Feb and occasionally Dec to Jan

     

    DEFPARAM CumulateOrders=false
    
    IF MONTH = 1 THEN
    
    buy 1 contract AT MARKET
    endif
    
    IF MONTH = 2 THEN
    
    sell 1 contract AT MARKET
    
    ENDIF
    #6706 quote
    Nicolas
    Keymaster
    Master

    The “sell” instruction mean you want to close your buy trades. Is that what you want to do here? Buy 1 contract if you are in January and then sell the same contract at the beginning of February? If yes, it would work.

    #6721 quote
    air
    Participant
    Average

    Yes, buy one month and sell the other. It works. However, I get different results with USD/JPY. Maybe, I just have a bug :)?

    #6725 quote
    Nicolas
    Keymaster
    Master

    Just tested it, it works well.

    Do you have sufficient amount of cash in your test? You’ll get margin call very quickly if you don’t have a big amount of cash. What timeframe are you testing?

    grid-orders-1.png grid-orders-1.png
    #6727 quote
    air
    Participant
    Average

    Monthly. 10 m yen. For example, I get 30 apr  2008 to 31 may 2010. It jumps 2 years.

    #6818 quote
    air
    Participant
    Average

    Apparently, on my hand,  it work fine with etfs, while it shows some discrepancies with futures.

    #6903 quote
    air
    Participant
    Average

    I am attaching one page results for soybeans futures. Looking forward to your kind answer.

    Thanks.

    SOYBEANS.pdf
    #7022 quote
    Nicolas
    Keymaster
    Master

    Please test on an inferior timeframe (weekly or daily one). Are you sure Soybeans Future history has this months?

    #7024 quote
    air
    Participant
    Average

    Good day Nicholas,

    Thank you for your reply.  d/w: it works.

    It also work fine with monthly CAC and DAX.

    Apparently, it has some problems with North American monthly futures.

    I am using the full MONTH, YEAR futures.

    #7284 quote
    air
    Participant
    Average

    Hi,

    Same problems with gold daily. Some months are ok (the whole database is used to calculate performance). For others, only a portion of the database is used without me changing anything. Sorry for it. I know you are very busy/doing a great job coding. Is there somebody I can talk to regarding the platform?

    #7298 quote
    Nicolas
    Keymaster
    Master

    Hi air,

    Sorry but i’m not so aware of Futures market history.

    If you make a simple indicator with :

    RETURN Month

    Does it show each month from 1 to 12 on screen?

    #7299 quote
    air
    Participant
    Average

    Hi Nicholas,

    Yes, the indicator shows each month 1/12 starting from 1975 for gold (nymex).

    #7301 quote
    Nicolas
    Keymaster
    Master

    and with the code changed to :

    DEFPARAM CumulateOrders=false
    
    IF MONTH = 1 THEN
     buy 1 contract AT MARKET
    endif
    
    IF MONTH = 2 THEN
     sell AT MARKET
    ENDIF

    Does it change something?

Viewing 15 posts - 1 through 15 (of 16 total)
  • You must be logged in to reply to this topic.

Some months yes others no


General Trading: Market Analysis & Manual Trading

New Reply
Author
author-avatar
air @air Participant
Summary

This topic contains 15 replies,
has 2 voices, and was last updated by air
9 years, 8 months ago.

Topic Details
Forum: General Trading: Market Analysis & Manual Trading
Language: English
Started: 05/09/2016
Status: Active
Attachments: No files
Logo Logo
Loading...