Spot the code error in afl please. - AmiBroker | futures io social day trading
futures io futures trading


Spot the code error in afl please.
Updated: Views / Replies:1,002 / 17
Created: by milkysahai001 Attachments:0

Welcome to futures io.

(If you already have an account, login at the top of the page)

futures io is the largest futures trading community on the planet, with over 90,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.

At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors Ė all of which you can find on futures io, utilizing our social trading environment.

With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you donít need to worry about fake reviews.

We are fundamentally different than most other trading sites:
  • We are here to help. Just let us know what you need.
  • We work extremely hard to keep things positive in our community.
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts.
  • We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

Reply
 
Thread Tools Search this Thread
 

Spot the code error in afl please.

  #11 (permalink)
Elite Member
Toronto Canada
 
Futures Experience: Intermediate
Platform: ninjatrader
Favorite Futures: es
 
mmaker's Avatar
 
Posts: 353 since Feb 2011
Thanks: 1,169 given, 392 received

also


milkysahai001 View Post
I am trying to code signals based on my own indicator, but the indicators are overlapping throughout on the chart. The formula for them is totally different but the values are coming same. Also there is no problem in compiling the afl. Can somebody point out the error in my code?

Vclose = 0;
Vclose = (Om+Hm+Lm+Cm)/4;
Vopen = 0;
Value1 = IIf (Ref (vOpen, -1) > 0, Ref(vOpen, -1), vClose);
Vopen = ((value1) + smooth * ( vClose - value1));

the values of vClose and vOpen should not come the same.
Please consider that I am newbie in afl coding.

dunno if it matters but you seem to be referencing the previous bar as well.

So you need to tell the program not to execute until x bars have been processed.

And you are assigning a value of zero to Vopen so Vopen will never be greater than zero.

I would initialize it to "1" to get it started.

Reply With Quote
The following user says Thank You to mmaker for this post:
 
  #12 (permalink)
Elite Member
Toronto Canada
 
Futures Experience: Intermediate
Platform: ninjatrader
Favorite Futures: es
 
mmaker's Avatar
 
Posts: 353 since Feb 2011
Thanks: 1,169 given, 392 received

That sounds like


prouser View Post
You have 300 posts and are member since 2011 and you are still unable to look at the link at the top which is clearly showing to you that you are in AmiBroker discussion area?

Please register on futures.io to view futures trading content such as post attachment(s), image(s), and screenshot(s).


Are you trolling?

Anyway with upper easy simple platform info are you still unable to use search engines? Really?
https://lmgtfy.com/?q=AmiBroker+AFL

That sounds like a shot. Is it? I wasn't looking for links and afl clues. I was looking for the answer.

hey, it was late at night. I was sitting in the dark, could barely see my keypad and i was just trying to help the guy/girl out.

i never heard of afl. and maybe i had and long forgotten about it. In fact when i had ami i am not sure if afl was around or not.

But i must not have liked it cuz i moved on to C#.

Reply With Quote
 
  #13 (permalink)
Membership Temporarily Revoked
Zurich/Switzerland
 
Futures Experience: Advanced
Platform: -
Favorite Futures: -
 
Posts: 79 since Oct 2014
Thanks: 0 given, 33 received



mmaker View Post
dunno if it matters but you seem to be referencing the previous bar as well.

So you need to tell the program not to execute until x bars have been processed.

And you are assigning a value of zero to Vopen so Vopen will never be greater than zero.

I would initialize it to "1" to get it started.


There is no initialization required. And as you might have noticed the solution has been given already. He is looking for Heikin Ashi. Several examples available on the Internet already (with or without looping).

Reply With Quote
 
  #14 (permalink)
Membership Temporarily Revoked
Zurich/Switzerland
 
Futures Experience: Advanced
Platform: -
Favorite Futures: -
 
Posts: 79 since Oct 2014
Thanks: 0 given, 33 received


mmaker View Post
That sounds like a shot. Is it?

We don't shoot here on the other side of the Atlantic.


mmaker View Post
I wasn't looking for links and afl clues. I was looking for the answer.

Then it has been a lazy attempt looking for an answer. Don't you think?


mmaker View Post
hey, it was late at night. I was sitting in the dark, could barely see my keypad and i was just trying to help the guy/girl out.

C'mon that's a pretty lame excuse. You can do better. Nevertheless I am not shooting at your attempt to help. Just saying.


mmaker View Post
i never heard of afl. and maybe i had and long forgotten about it. In fact when i had ami i am not sure if afl was around or not.

But i must not have liked it cuz i moved on to C#.

Since you never heard of it your conclusion is not really making sense.

FYI, there always has been the ability to code in AFL, C/C++, NET, .. in AmiBroker. Many choices instead of just one.

Last but not least here is a "shot" you were looking for (?)... since you were coding until late at night I can tell you that you would have been finished hours before late at night if coding in AFL instead of C# and as such you could have given better help to OP at daylight. Result: doing more pleasing things late at night. At least that's how I do it and it's fun.


Reply With Quote
The following 2 users say Thank You to prouser for this post:
 
  #15 (permalink)
Elite Member
Toronto Canada
 
Futures Experience: Intermediate
Platform: ninjatrader
Favorite Futures: es
 
mmaker's Avatar
 
Posts: 353 since Feb 2011
Thanks: 1,169 given, 392 received

Congrats


prouser View Post
We don't shoot here on the other side of the Atlantic.



Then it has been a lazy attempt looking for an answer. Don't you think?



C'mon that's a pretty lame excuse. You can do better. Nevertheless I am not shooting at your attempt to help. Just saying.



Since you never heard of it your conclusion is not really making sense.

FYI, there always has been the ability to code in AFL, C/C++, NET, .. in AmiBroker. Many choices instead of just one.

Last but not least here is a "shot" you were looking for (?)... since you were coding until late at night I can tell you that you would have been finished hours before late at night if coding in AFL instead of C# and as such you could have given better help to OP at daylight. Result: doing more pleasing things late at night. At least that's how I do it and it's fun.


You are the first one to make it to my ignore list. Adios.

Reply With Quote
 
  #16 (permalink)
Membership Temporarily Revoked
Zurich/Switzerland
 
Futures Experience: Advanced
Platform: -
Favorite Futures: -
 
Posts: 79 since Oct 2014
Thanks: 0 given, 33 received

Seems I have been spot on.

Anyway contrary to adios (== negativity) I'm saying cu later (== hope).

Reply With Quote
 
  #17 (permalink)
Site Administrator
Manta, Ecuador
 
Futures Experience: Advanced
Platform: My own custom solution
Favorite Futures: E-mini ES S&P 500
 
Big Mike's Avatar
 
Posts: 46,168 since Jun 2009
Thanks: 29,280 given, 82,799 received

The user prouser has been banned for rude behavior. I fully expect him to create another duplicate account and come back, in violation of our rules, which he has no respect for.

Be on the lookout...

Sent using the futures.io mobile app

Due to time constraints, please do not PM me if your question can be resolved or answered on the forum.

Need help?
1) Stop changing things. No new indicators, charts, or methods. Be consistent with what is in front of you first.
2) Start a journal and post to it daily with the trades you made to show your strengths and weaknesses.
3) Set goals for yourself to reach daily. Make them about how you trade, not how much money you make.
4) Accept responsibility for your actions. Stop looking elsewhere to explain away poor performance.
5) Where to start as a trader? Watch this webinar and read this thread for hundreds of questions and answers.
6)
Help using the forum? Watch this video to learn general tips on using the site.

If you want
to support our community, become an Elite Member.

Reply With Quote
 
  #18 (permalink)
Trading Apprentice
Agra+India
 
Futures Experience: Beginner
Platform: MultiCharts, AmiBroker
Favorite Futures: Stock Futures
 
Posts: 42 since Sep 2016
Thanks: 17 given, 3 received


prouser View Post
You have 300 posts and are member since 2011 and you are still unable to look at the link at the top which is clearly showing to you that you are in AmiBroker discussion area?

Please register on futures.io to view futures trading content such as post attachment(s), image(s), and screenshot(s).


Are you trolling?

Anyway with upper easy simple platform info are you still unable to use search engines? Really?
https://lmgtfy.com/?q=AmiBroker+AFL


Big Mike View Post
The user prouser has been banned for rude behavior. I fully expect him to create another duplicate account and come back, in violation of our rules, which he has no respect for.

Be on the lookout...

Sent using the futures.io mobile app


Thanks Big Mike.

Reply With Quote

Reply



futures io > > > > Spot the code error in afl please.

Thread Tools Search this Thread
Search this Thread:

Advanced Search



Upcoming Webinars and Events (4:30PM ET unless noted)
 

RandBots: AutoTrading Bots to diversify your trading

Oct 24
 

TopstepTrader: Profiting Without Risking Your Own Money

Oct 26

Building Open Source Indicators for NT8 w/Fat Tails @ Lizard Indicators

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
AFL Error 61 Jacare AmiBroker 2 March 23rd, 2016 09:55 AM
Need afl venkatbabu AmiBroker 1 June 1st, 2014 10:27 AM
need Amibroker afl venkatbabu AmiBroker 2 May 29th, 2014 08:31 AM
joeHAOindicator fails to compile with error code cs0542 joemiller NinjaTrader Programming 2 May 27th, 2013 03:21 PM
Help with code error kashter NinjaTrader Programming 10 March 8th, 2011 11:16 AM


All times are GMT -4. The time now is 05:55 AM.

Copyright © 2017 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
All information is for educational use only and is not investment advice.
There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
no new posts
Page generated 2017-10-23 in 0.14 seconds with 35 queries on phoenix via your IP 54.167.250.64