Renko3 Alert

The custom signals are published in this forum.

Moderator: admin

Renko3 Alert

Postby vstrelnikov » Wed Jan 23, 2013 1:42 pm

Signals when Renko indicator changes direcion.


Renko3_Alert.png


Code: Select all
function Init()
    strategy:name("Indicator alert");
    strategy:description("Alerts when a Renko3 indicator/oscillator crosses a certain level");

    strategy.parameters:addGroup("Renko3 Parameters");

    strategy.parameters:addString("Period", "Period size", "", "m1");
    strategy.parameters:setFlag("Period", core.FLAG_PERIODS);
   
    strategy.parameters:addString("Type", "Price type", "", "Bid");
    strategy.parameters:addStringAlternative("Type", "Bid", "", "Bid");
    strategy.parameters:addStringAlternative("Type", "Ask", "", "Ask");

    strategy.parameters:addInteger("Step", "Step in pips", "", 100);

    strategy.parameters:addGroup("Notification");

    strategy.parameters:addBoolean("ShowAlert", "Show Alert", "", true);
    strategy.parameters:addBoolean("PlaySound", "Play Sound", "", false);
    strategy.parameters:addFile("SoundFile", "Sound File", "", "");
    strategy.parameters:setFlag("SoundFile", core.FLAG_SOUND);
    strategy.parameters:addBoolean("SendEmail", "Send Email", "", false);
    strategy.parameters:addString("Email", "E-mail address", "Note that to recieve e-mails, SMTP settings must be defined (see Signals Options).", "");
    strategy.parameters:setFlag("Email", core.FLAG_EMAIL);


end

local SoundFile;
local gSource = nil;        -- the source stream
local ZigAndZag
local SendEmail, Email;
local lastSignal = nil

function Prepare()

   gSource = ExtSubscribe(1, nil, instance.parameters.Period, instance.parameters.Type == "Bid", "bar");
   I = core.indicators:create("RENKO3", gSource, instance.parameters.Step)
   tickSource = ExtSubscribe(2, nil, "t1", instance.parameters.Type == "Bid", "bar");

   ShowAlert = instance.parameters.ShowAlert;

   if instance.parameters.PlaySound then
        SoundFile = instance.parameters.SoundFile;
    else
        SoundFile = nil;
    end

    assert(not(PlaySound) or (PlaySound and SoundFile ~= ""), "Sound file must be specified");

    SendEmail = instance.parameters.SendEmail;
    if SendEmail then
        Email = instance.parameters.Email;
    else
        Email = nil;
    end
    assert(not(SendEmail) or (SendEmail and Email ~= ""), "E-mail address must be specified");
 
    local name = profile:id() .. "(" .. instance.bid:instrument()  .. "(" .. instance.parameters.Period  .. ")" .. ", Renko3)";
    instance:name(name);

    ExtSetupSignal("Renko3 Alert: ", ShowAlert);
    ExtSetupSignalMail(name);
end

-- when tick source is updated
function ExtUpdate(id, source, period)
    -- update indicator

    if I ~= nil then
        I:update(core.UpdateLast);
    end
   
   if I.DATA:size() < 2 then
      return;
   end

    local sz = I.open:size() - 1

    if I.open[sz] >= I.close[sz] and I.open[sz - 1] < I.close[sz - 1] and lastSignal ~= "Sell" then
        lastSignal = "Sell"
        ExtSignal(gSource, sz, "Sell", SoundFile, Email);
    elseif I.open[sz] < I.close[sz] and I.open[sz - 1] >= I.close[sz - 1]  and lastSignal ~= "Buy" then
        lastSignal = "Buy"
        ExtSignal(gSource, sz, "Buy", SoundFile, Email);
    end
end

dofile(core.app_path() .. "\\strategies\\standard\\include\\helper.lua");
Attachments
Renko3_Alert.lua
(3.14 KiB) Downloaded 2629 times
vstrelnikov
 
Posts: 59
Joined: Tue Jul 06, 2010 8:31 pm

Re: Renko3 Alert

Postby RunVert » Wed Jan 23, 2013 1:57 pm

IS there a Renko chart that is fully operational yet?
the following thread has not been updated since September and the renko chart still crashes when trying to change the box size or the time frame.

http://fxcodebase.com/code/viewtopic.ph ... 0&start=20

Alert look nice. Good work!
RunVert
 
Posts: 23
Joined: Wed Jan 23, 2013 12:32 pm

Re: Renko3 Alert

Postby beatrice3 » Sun Feb 02, 2014 4:54 pm

Hi,
I downloaded and imported this successfully, but when I try to add it to the marketscope chart I get the following error message:

Renko3_Alert.lua:38: The indicator with id RENKO3 is not found

Can anyone help??

Thanks :)
beatrice3
 
Posts: 4
Joined: Sun Feb 02, 2014 4:48 pm

Re: Renko3 Alert

Postby Apprentice » Mon Feb 03, 2014 5:47 am

Please Download and Install This Indicator.
download/file.php?id=3130
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36341
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Renko3 Alert

Postby SenseClash » Fri Feb 26, 2016 12:42 pm

I have some questions. I have my Renkos set on the 1-minute chart for 20 pips.
1) When I hover over a Renko and the time underneath is, say, 05:40 am, is that the time when the Renko candle BEGAN to form or when it STOPPED forming?

2) What's the difference between a setting of "1-minute chart 20 pips" versus "5-minute chart 20 pips"? Does the first one check every minute to see if there's been 20 pips of movement and the second one check every 5 minutes?

I set the alert for several pairs. I got email notifications for EURUSD, GBPUSD, USDJPY and USDCAD, but the "Events" tab only lists the very first signal I got. The other 3 signals from tonight aren't listed.
3) Why is only the first signal I received (EURUSD) listed in the "Events" tab?

Also, one of my pairs didn't signal, but should have (the AUDUSD). The settings for all alerts are exactly the same.
4) Why didn't the AUDUSD give a signal?

For reference, below are the times that appear when I hover under a candle and when my email notification appeared. (The EUR and JPY email notifications seem late.)
EURUSD: 3:31 4:02
GBPUSD: 5:40 5:42
USDJPY 5:06 5:48
USDCAD 7:44 7:44
SenseClash
 
Posts: 24
Joined: Sun Jul 13, 2014 12:16 pm

Re: Renko3 Alert

Postby SenseClash » Fri Feb 26, 2016 1:00 pm

Is this tab why I only got a signal for the Euro? The label for this tab makes it sound like it is only about Euro signals.
Attachments
eur events tab.png
SenseClash
 
Posts: 24
Joined: Sun Jul 13, 2014 12:16 pm

Re: Renko3 Alert

Postby MrRiversideDude » Thu Mar 17, 2016 7:52 am

Can we add one MA to this alert that's based on the Renko3 bars? It should alert buy if above the MA, sell if below the MA.

Thanks in advance!
MrRiversideDude
 
Posts: 87
Joined: Fri Feb 21, 2014 7:50 am

Re: Renko3 Alert

Postby MrRiversideDude » Fri Mar 18, 2016 9:08 am

I'm willing to pay $25 US Dollars via Paypal to whoever gets this done and it works after I test it.

Thanks in advance!
MrRiversideDude
 
Posts: 87
Joined: Fri Feb 21, 2014 7:50 am

Re: Renko3 Alert

Postby SenseClash » Sat Mar 19, 2016 8:58 pm

MrRiversideDude wrote:Can we add one MA to this alert that's based on the Renko3 bars? It should alert buy if above the MA, sell if below the MA.

Thanks in advance!



I like this idea, too!
SenseClash
 
Posts: 24
Joined: Sun Jul 13, 2014 12:16 pm

Re: Renko3 Alert

Postby MrRiversideDude » Mon Mar 21, 2016 12:44 am

Why can't we get this simple change done? Is it possible? If so, it seems like it would only take five minutes for one of the experts.

Thanks in advance.
MrRiversideDude
 
Posts: 87
Joined: Fri Feb 21, 2014 7:50 am

Next

Return to Custom Signals

Who is online

Users browsing this forum: No registered users and 8 guests