no signal appearing on the chart with this simple code  [SOLVED]

Questions about MultiCharts and user contributed studies.
ravel44
Posts: 28
Joined: 05 Jul 2012
Has thanked: 7 times

no signal appearing on the chart with this simple code  [SOLVED]

Postby ravel44 » 26 Oct 2015

Hello !
I am surprised to get no signal in my 1 minute chart when I type the simple code below, I should have a signal at 9:33. I ve been unable to understand why

if
time=933
then
sell 100 shares this bar on close;

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

Re: no signal appearing on the chart with this simple code

Postby TJ » 26 Oct 2015

Hello !
I am surprised to get no signal in my 1 minute chart when I type the simple code below, I should have a signal at 9:33. I ve been unable to understand why

if
time=933
then
sell 100 shares this bar on close;
See post #7
viewtopic.php?f=16&t=10811

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

Re: no signal appearing on the chart with this simple code

Postby TJ » 26 Oct 2015

ps.

[FAQ] How to Post Codes (... so that people can read)
viewtopic.php?f=16&t=11713

ravel44
Posts: 28
Joined: 05 Jul 2012
Has thanked: 7 times

Re: no signal appearing on the chart with this simple code

Postby ravel44 » 26 Oct 2015

Hello !
I am surprised to get no signal in my 1 minute chart when I type the simple code below, I should have a signal at 9:33. I ve been unable to understand why

if
time=933
then
sell 100 shares this bar on close;
See post #7
viewtopic.php?f=16&t=10811
thank U
I change my code to the following but still don t see any signal. I usually have no problem displaying sgnals

Code: Select all

if
time=933
then
sell 100 shares next bar at market;

tony
Posts: 420
Joined: 14 Jun 2013
Has thanked: 30 times
Been thanked: 81 times
Contact:

Re: no signal appearing on the chart with this simple code

Postby tony » 26 Oct 2015

Not sure if this matters, didn't test, but try time = 0933, versus time = 933

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

Re: no signal appearing on the chart with this simple code

Postby TJ » 26 Oct 2015

Hello !
I am surprised to get no signal in my 1 minute chart when I type the simple code below, I should have a signal at 9:33. I ve been unable to understand why

if
time=933
then
sell 100 shares this bar on close;
See post #7
viewtopic.php?f=16&t=10811
thank U
I change my code to the following but still don t see any signal. I usually have no problem displaying sgnals

Code: Select all

if
time=933
then
sell 100 shares next bar at market;
A few questions:

1. Which Multicharts version you are using?
2. What is the symbol?
3. Is it a thinly traded instrument? ie. were there trades between 932 and 934?
4. Did you turn on autotrade? (I know it is a silly question, but you never know until you asked).

ravel44
Posts: 28
Joined: 05 Jul 2012
Has thanked: 7 times

Re: no signal appearing on the chart with this simple code

Postby ravel44 » 26 Oct 2015

Not sure if this matters, didn't test, but try time = 0933, versus time = 933
I tried but no change, thanks though

tony
Posts: 420
Joined: 14 Jun 2013
Has thanked: 30 times
Been thanked: 81 times
Contact:

Re: no signal appearing on the chart with this simple code

Postby tony » 26 Oct 2015

It time = 0933

then sellshort 100 shares next bar at market;

I assume you want to go short, by saying sell 100 shares, you are I believe saying exit a long position and you are flat. Try that.

ravel44
Posts: 28
Joined: 05 Jul 2012
Has thanked: 7 times

Re: no signal appearing on the chart with this simple code

Postby ravel44 » 26 Oct 2015


A few questions:

1. Which Multicharts version you are using?
2. What is the symbol?
3. Is it a thinly traded instrument? ie. were there trades between 932 and 934?
4. Did you turn on autotrade? (I know it is a silly question, but you never know until you asked).

I use MC9.1
Ticker: AAPL, only using highly traded tickers
I imported the signal on the chart as I always do and the status is on

ravel44
Posts: 28
Joined: 05 Jul 2012
Has thanked: 7 times

Re: no signal appearing on the chart with this simple code

Postby ravel44 » 26 Oct 2015

It time = 0933

then sellshort 100 shares next bar at market;

I assume you want to go short, by saying sell 100 shares, you are I believe saying exit a long position and you are flat. Try that.
I tried, no success. I attached a picture if it can help figuring out what s going on
Attachments
Screen Shot 2015-10-26 at 8.17.55 PM.png
(140.2 KiB) Downloaded 998 times

tony
Posts: 420
Joined: 14 Jun 2013
Has thanked: 30 times
Been thanked: 81 times
Contact:

Re: no signal appearing on the chart with this simple code

Postby tony » 26 Oct 2015

I'm not trying these suggestions, my machine is off line.

Try one more thing:

If marketposition=0

AND time = 0933

then begin

sellshort 100 shares next bar at market;

end;

tony
Posts: 420
Joined: 14 Jun 2013
Has thanked: 30 times
Been thanked: 81 times
Contact:

Re: no signal appearing on the chart with this simple code

Postby tony » 26 Oct 2015

Make sure max bars back is sufficient, I can't tell from your screenshot.

ravel44
Posts: 28
Joined: 05 Jul 2012
Has thanked: 7 times

Re: no signal appearing on the chart with this simple code

Postby ravel44 » 26 Oct 2015

I'm not trying these suggestions, my machine is off line.

Try one more thing:

If marketposition=0

AND time = 0933

then begin

sellshort 100 shares next bar at market;

end;
I finally got it right. I had to put a larger # for the barsback, this was the solution
Attachments
Screen Shot 2015-10-26 at 8.35.11 PM.png
(104.22 KiB) Downloaded 995 times


Return to “MultiCharts”