GithubHelp home page GithubHelp logo

earnforex / positionsizer Goto Github PK

View Code? Open in Web Editor NEW
377.0 30.0 152.0 1.3 MB

Calculate your position size based on the risk and account size and execute your trades with this free MetaTrader expert advisor.

Home Page: https://www.earnforex.com/metatrader-expert-advisors/Position-Sizer/

License: Apache License 2.0

MQL5 83.86% MQL4 16.14%
risk trade currency calculations mql4 mql5 forex trading metatrader mt4

positionsizer's Introduction

Support Ukraine Badge

Position Sizer

The Position Sizer expert advisor for MT4 and MT5 by EarnForex.com.

The Position Sizer automatically calculates the number of lots to trade based your risk tolerance, account size and currency, currency pair, commission, and other settings.

It is a feature-rich expert advisor that was designed to work with all kinds of instruments and to help with everything related to position sizing - margin, potential portfolio risk & profit, swaps, and so on.

The Position Sizer - an example chart with ATR settings enabled

The Position Sizer EA can be used to open trades based on the calculations it does in the Main tab of its panel.

A very detailed description of the expert advisor and its functions can be found here: https://www.earnforex.com/metatrader-expert-advisors/Position-Sizer/

Installation instructions: https://www.earnforex.com/metatrader-expert-advisors/Position-Sizer/#Installation

All sorts of contributions are welcome!

positionsizer's People

Contributors

akhater avatar amrali-eg avatar earnforex avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

positionsizer's Issues

PSC-Trader Script Issue

Hi Team,

I upgraded to the latest version (2.34) for MT4. When I set the order to Long or Short with Order set to Instant, my order is a Buy Limit. Please refer to the screenshot shown below.

I reverted back to version 2.28 and I set the order to Buy with Order set to Instant, my order is a Buy.

Thanks in advance.

Regards,

Jon

234 issue

issue

my m.t error this
ModuleNotFoundError: No module named 'include.trade'
how can i fix it?

lot size calculation issue with a particular broker jpy pairs

hi dear developer , on this broker M4markets i get wrong calculation for JPY pairs , i know PSC works correct on every other broker i have ever tried and probably something is weird about this broker's servers , i have explained this issue with their support but they don't seem to be even understanding it.

i don't know if that possible or not but can PSC adapt to these type of brokers in next updates please?

Unable to add Points Value for TP2 or TP3 with Version 2.37

Hi,

I updated to the latest version (2.37) today, and I have tried to add 2 take profits using the ScriptTakeProfitsNumber function, however when I try to define how many points away I would like the Take Profit to be the number is automatically changing to another number. For example, my take profit 1 is 300 points (this can be changed to whatever I like and stays the same), my take profit 2 I tried to put in 600 points but as soon as it is entered it changes to 59922345. I think you have a bug here, but I apologise if this is something on my end, but I am not sure what this could be at the moment.

If there is another way I can place one trade and have a partial profit automatically triggered at a predefined level using your app please let me know. Thank you

Invalid TP issue on some pairs like EURGBP

image

Noticed an issue as PSC will not calculate risk, reward or lots on a few pairs but works on others.
Strangely it does not display the Entry, TP or SL lines automatically on those pairs despite the Order Type being set to "Instant".
When changed to pending and Entry/TP/SL prices manually entered, still gives "Invalid TP"

image

Incorrect Pip Value on Micro Futures

Hello,

In version 2.27 this worked correctly in version 2.33 the Pip Value is wrong. I'm not much of a coder but I am trying to find the difference or what changed to make this happen, so if I find I'll post again. If someone has time to look into this it would be appreciated.

I've included screen shots showing the difference. The left side is the correct Pip value. I also imagine this may mess up the SL/TP on futures like S&P and Nasdaq as the SL/TP has to be set at .25 levels. I haven't tested to see if the SL/TP is properly place as of yet.

This is MT5 with Futures broker ampfutures

v227_v233_01

v227_v233_02

Misscalculation: Maximum 1000 CFD can be opened

XXXXXEDITXXXXX
Was an issue with the broker, not with the calculator. Please ignore.

The Calculator does in no case calculate a max position size greater than 1000. Neither for the Margin calculation nor for the actual position size bought by the script. It comes to effect when you trade (cheap) cfd on stocks with tight SL.

Help with SL Panel Button

Hello,

I recently purchased a new computer and reinstalled Position Size Calculator v2.42. After entering all the inputs, I can't get the "Stop-loss:" button to work in the main panel. This use to move the SL line to a specified number of pips below/above the entry line. The Take-profit button works appropriately and moves the TP line below/above the entry line when activated, but the SL button doesn't do anything. Any suggestions? I've tried re-compiling it, and still doesn't work.

Chris

1657998753668
1657998777487
1657998897329

Position size incorrectly calculated when entry button is toggled with ATR SL multiplier

Environment:

  • Position Size Calculator version: 2.27
  • MT 5.00 build 2361 (8 Mar 2020)

Issue:
Calculated position size when between entry type sell/buy is up to 100x different, e.g. starts at 1.82, click to sell, shows 0.05, click to buy shows 12.79. The position size shown is often invalid for the trading account showing "Not enough money" in MT5.

Steps to recreate:

  1. Open EURAUD daily chart
  2. Display Position Size Calculator (ShowATROptions: true)
  3. Ensure ATR period: 14, SL multiplier: 1.50, ATR timeframe: PERIOD_D1, Risk (%): 2
  4. Take note of Position Size
  5. Click entry button (labelled "Buy @") changes to "Sell @"
  6. Take note of Position Size
  7. Click entry button (labelled "Sell @") changes to "Buy @"
  8. Take note of Position Size
  9. Compare position sizes.

Image1-Startup
PositionSizeCalculator-MT5-Image1-Startup

Image2-Sell
PositionSizeCalculator-MT5-Image2-Sell

Image3-Buy
PositionSizeCalculator-MT5-Image3-Buy

manually adjustable TP1 line

hello dear developer, is it possible to have an adjustable TP1 line? right now it gets overrides when it moved manually to TP ratio input level. i couldn't find any settings to do that.

thanks in advance

Possible bug with using zero stop loss in short trade

Hi
Thanks very much for this wonderful EA. Your effort is very much appreciated.

When setting up a short trade on the EA, setting zero stop loss in the edit box automatically by itself changes the Short button to long.
The button goes from showing Short to showing Long.

For now i just use very high stop loss to avoid the problem.

Cheers.

Request for change multiple TP management

Hello dear developer, would you please consider change the way PSC manages the multiple TP orders to maybe have a fixed distance(maybe a percentage of the main TP or a fixed RR but hidden lines) for additional TPs? sometimes if one of TP lines be in a invalid price level(for a buy position it being lower than entry point) it opens the trade but without stoploss. and also multiple TP lines makes the chart a bit messy and hard to manage when you want open a trade. also if i set TP to be set by point and not price level the additional TPs distance convert to unrealistic point values.

sometimes you just want break your trade into smaller positions and specific TP levels in not important at the time of opening the trade.

is it possible to change it a little bit please? Thanks in advance

MT5 2.34 Infinite automatic switch between tiles when PSC is minimized

Hi there and thanks for a fantastic tool that I use everyday.

I was excited by the changelog of v2.34 as it solves a couple of inconveniences that drove me nuts (that Stop Line! lol) but halas I'm running into an issue before I even get to use the tool properly.

This is on MT5, v2.34. The moment the indicator is minimised, there seems to be an automatic loop on that pulls focus back on this pair/tab/tile.
If I load the indicator on a 2nd pair and minimise the panel there then MT5 just automatically switches between the 2 pairs that have the indicator minimised. It gets worse if I can load it on a 3rd pair, it switches between the 3 so fast. It becomes impossible to do anything. The behaviour stops when the panel is "opened" or "maximised".

I've restarted MT5 several times, unloaded the indicator properly, loaded it back up and the same behaviour appears everytime. This is on default settings.

It doesn't happen on MT4 v2.34.

Lot size with multiple profit targets

Hi,
Thanks for the great tool.

I use it with multiple profit targets in an account with little funds. The issue I observe is that the distribution of the lot size by the different portions of the trade doesn't look correct.
I attach an example where I have 4 PT with 25% each, and one of the portions has 0.04 and the others 0.01. Ideally, they should all have the same lot size but since that's not possible (unit is 0.01 lots), I believe a 0.02, 0.02, 0.02, 0.01 lots would make more sense.

There are other small issues relative to multiple PT:

  • When the number of PT is changed, the percentage distributions of the PT get messed up but don't become red to indicate an error.
  • If I have 3 PT, it accepts 33% in each (doesn't become red) but that gives different lot sizes than 34%, 33%, 33%. seems something is not quite right.

Screenshot 2022-11-10 145609

Kind Regards, Jaime.

Feature request: When TP1 is met on the first part of position, move second position SL to Break Even

Hi,
Would it be possible to add a feature, where if more than one Take Profit is set (TP1, TP2, TP3...), once TP1 is met, the Stop Loss (SL) is automatically moved to the Break Even (BE).

Scenario: TP1 is hit and 50 % of the position is closed. For the remaining 50 % of the position, SL is moved to BE and the remaining position either hits TP2 for additional profit, or hits the Stop Loss now at Break Even.

As a bonus feature sometime in the future, it would be cool of the Stop Loss could become a Trailing Stop (either set as a fixed number of pips or by current ATR) and be set either from Break Even point or xx pips/ATR away from the current price.

Thank you in advance!

Moving SL/TP from default ATR requires several attempts during high volume

I've had this issue with 2.x and 3.x. Same issue in 3.0.2.

I've compiled with the following changes:

input bool ShowATROptions = true
input double DefaultATRMultiplierSL = 1
input double DefaultATRMultiplierTP = 2
input ENTRY_TYPE DefaultEntryType = Pending

  1. Open Position Sizer on chart (SL and TP lines show correctly)
  2. Attempt to drag the SL/TP can required 10+ attempts as it keeps resetting back to the original last position

It seems that on a new tick it will get reset unless you moved it before the tick came in. So it's easier to set when market volume is low.

BTW, this is an amazing tool and I'm always recommending it. Unless you've coded in MQL you'll have no idea the amount of time and effort this project must have taken. Much respect team! ;-)

ATR stoploss adjustment improvement

Currently when you want a stop loss set automatically by a ATR multiple it adds or substracts the distance from the entry level which makes sense and now problem here. But what about those who wants a ATR stop based on a near by swing? Why not add an extra line that the user can move towards the swing/support/resistance level that he/she wants the ATR stop value added or substracted from? So maybe create an option where if placed to true the user can manually set where he/she wants the ATR stop value added/substracted from if he/she feels they don't want to make use of the entry level as a level to adjust ATR stop from, but rather place the stop loss automatically a distance from the support/resistance level manually adjusted by the user. It would be a great add of a function and solve of the problem having to only stick to the entry level as a level the ATR is deducted/added from/to. Another bonus would be if the spread is also taking in consideration when calculating the ATR stop when you are selling a position. By this I mean: stoploss = (atr * multiplier) + entry level/support/resistance level + spread.. When entering a sell we exit by the ask price line not the bid price line, so in currency pairs with larger spread it makes better sense to take in consideration the adding of the spread to the sell stoploss to cater for the distance of spread as the price approaches your sell stoploss. For a buy position its not needed cause a buy position is exited by bid price. This will be more noticeable for intra-day traders and scalpers that has to deal with some spreads that is not that in their favour for a while. Please consider thank you.

Take Profit and Stop Loss Lines not Setting Correctly (Ver. 2.41)

Hi,

While setting up a trade, when I try and move the stop loss or take profit line with my mouse, on the chart, I set where I would like the SL or TP to be, the lines skip back to where they were before I moved them. The only way I seem to be able to move them, without the lines skipping back to where they were, is by moving the lines as quickly as possible, and even then it takes me a couple of tries. The lines seem to skip back when the price changes, so in calmer hours it's not much of a problem, but when price is moving a little, it's a bit of a challenge.

Not a big issue to be honest, as I can type in the price or points in the GUI, but it would be nice if this worked a bit smoother.

Thank you for the great application.

Issue with the function CountDecimalPlaces()

I suggest the following as improvement.

#define PRINT( A) Print( #A + " = ", (A))

//+------------------------------------------------------------------+
//| Counts decimal places.                                           |
//+------------------------------------------------------------------+
//int CountDecimalPlaces(double number)
//{
//   // 100 as maximum length of number.
//   for (int i = 0; i < 100; i++)
//   {
//      if (MathAbs(MathRound(number) - number) / MathPow(10, i) <= FLT_EPSILON) return(i); // For some reason DBL_EPSILON doesn't work here.
//      number *= 10;
//   }
//   return(-1);
//}

int CountDecimalPlaces(double number)
{
   // 100 as maximum length of number.
   for (int i = 0; i < 100; i++)
   {
      double pwr = MathPow(10, i);
      if (MathRound(number * pwr) / pwr == number) return(i);
   }
   return(-1);
}
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
void OnStart()
  {
   Print("======== Testing CountDecimalPlaces() ========");
   PRINT( CountDecimalPlaces(1) == 0 );
   PRINT( CountDecimalPlaces(0.1) == 1 );
   PRINT( CountDecimalPlaces(0.01) == 2 );
   PRINT( CountDecimalPlaces(0.001) == 3 );
   PRINT( CountDecimalPlaces(0.0001) == 4 );
   PRINT( CountDecimalPlaces(0.00001) == 5 );
   PRINT( CountDecimalPlaces(0.000001) == 6 );
   PRINT( CountDecimalPlaces(0.0000001) == 7 );
   PRINT( CountDecimalPlaces(0.00000001) == 8 );
   PRINT( CountDecimalPlaces(0.000000001) == 9 );
   PRINT( CountDecimalPlaces(0.0000000001) == 10 );
   PRINT( CountDecimalPlaces(0.00000000001) == 11 );
   PRINT( CountDecimalPlaces(0.000000000001) == 12 );
   PRINT( CountDecimalPlaces(0.0000000000001) == 13 );
   PRINT( CountDecimalPlaces(0.00000000000001) == 14 );
   PRINT( CountDecimalPlaces(0.000000000000001) == 15 );
   PRINT( CountDecimalPlaces(0.0000000000000001) == 16 );
   PRINT( CountDecimalPlaces(0.00000000000000001) == 17 );
   PRINT( CountDecimalPlaces(0.000000000000000001) == 18 );
   PRINT( CountDecimalPlaces(0.0000000000000000001) == 19 );

   PRINT( CountDecimalPlaces(1) == 0 );
   PRINT( CountDecimalPlaces(1.1) == 1 );
   PRINT( CountDecimalPlaces(1.12) == 2 );
   PRINT( CountDecimalPlaces(1.123) == 3 );
   PRINT( CountDecimalPlaces(1.1234) == 4 );
   PRINT( CountDecimalPlaces(1.12345) == 5 );
   PRINT( CountDecimalPlaces(1.123456) == 6 );
   PRINT( CountDecimalPlaces(1.1234567) == 7 );
   PRINT( CountDecimalPlaces(1.12345678) == 8 );
   PRINT( CountDecimalPlaces(1.123456789) == 9 );
   PRINT( CountDecimalPlaces(1.1234567891) == 10 );
   PRINT( CountDecimalPlaces(1.12345678912) == 11 );
   PRINT( CountDecimalPlaces(1.123456789123) == 12 );
   PRINT( CountDecimalPlaces(1.1234567891234) == 13 );
   PRINT( CountDecimalPlaces(1.12345678912345) == 14 );
   PRINT( CountDecimalPlaces(0.012345678912345) == 15 );
   PRINT( CountDecimalPlaces(0.0123456789123456) == 16 );
   PRINT( CountDecimalPlaces(0.00123456789123456) == 17 );
   PRINT( CountDecimalPlaces(0.000123456789123456) == 18 );
   PRINT( CountDecimalPlaces(0.0000123456789123456) == 19 );

   PRINT( CountDecimalPlaces(1.12) == 2 );
   PRINT( CountDecimalPlaces(1.14) == 2 );
   PRINT( CountDecimalPlaces(1.36) == 2 );
   PRINT( CountDecimalPlaces(1.57) == 2 );
   PRINT( CountDecimalPlaces(1.93) == 2 );
   PRINT( CountDecimalPlaces(1.118) == 3 );
   PRINT( CountDecimalPlaces(1.378) == 3 );
   PRINT( CountDecimalPlaces(1.757) == 3 );
   PRINT( CountDecimalPlaces(1.816) == 3 );
   PRINT( CountDecimalPlaces(90.268) == 3 );
   PRINT( CountDecimalPlaces(1.0778) == 4 );
   PRINT( CountDecimalPlaces(1.0954) == 4 );
   PRINT( CountDecimalPlaces(1.2749) == 4 );
   PRINT( CountDecimalPlaces(0.85919) == 5 );
   PRINT( CountDecimalPlaces(1.09545) == 5 );
   PRINT( CountDecimalPlaces(1.26008) == 5 );
   PRINT( CountDecimalPlaces(1.27481) == 5 );
   PRINT( CountDecimalPlaces(1.27483) == 5 );
   PRINT( CountDecimalPlaces(1.27571) == 5 );
   PRINT( CountDecimalPlaces(1.30418) == 5 );
   PRINT( CountDecimalPlaces(1.42147) == 5 );
   PRINT( CountDecimalPlaces(1.54289) == 5 );
   PRINT( CountDecimalPlaces(1.56849) == 5 );
   PRINT( CountDecimalPlaces(1.61465) == 5 );
   PRINT( CountDecimalPlaces(1.69292) == 5 );
  }
//+------------------------------------------------------------------+

PositionSizeCalculator Gets Removed Automatically Whenever Switching Timeframes...

Hi,

I've been enjoying this wonderful tool for years and it has never failed me. However today upon updating from v2.41 to current v2.42 I encountered an issue which needs urgent attention. Upon compiling both PSC and PSC Script like usual, I was able to do the computation with PSC, say in H4 Timeframe (TF). BUT then whenever I switch to say D1 or any other TFs PSC automatically gets removed from my MT4 chart. Below is what I got upon checking the Journal section:-

"2022.05.14 23:41:51.304 Custom indicator PositionSizeCalculator EURUSD.ecn,Daily: removed"

I can reinstall and reattach the PSC again on D1 TF and I get this from the Journal:

"2022.05.14 23:52:04.828 Custom indicator ......\PositionSizeCalculator v2.41\PositionSizeCalculator EURUSD.ecn,Daily: loaded successfully"

BUT again when I switch to another TF, it gets removed immediately with this message in the Journal:

"2022.05.14 23:54:17.412 Custom indicator PositionSizeCalculator EURUSD.ecn,H1: removed"

I then proceeded to delete all traces of the current v2.42 and reinstalled the older v2.41 in hopes that it goes back to normal for me. However, even switching back to the older version doesn't help! The same issue keeps popping up. I definitely can attach PSC onto say H1 TF..., but whenever I switch to another TF it gets removed immediately... HELP please. Aargghh...

Can someone pls look into this urgently as I can't trade successfully with such interruptions when the software gets removed when it matters most during trading when I depend on this awesome tool/software.

Much thanks 🙏 for the wonderful work put into this thus far. Kudos to all...

I wait patiently for the rectification...

Sincerely,
GL Tan
PSC error pg1

PSC error pg2

chaging initial risk to reset symbols to default

It would be more logical if when you change the initial risk in inputs menu to reset all symbols initial risk. Right now it reads the values from symbol specific setting that is saved in "file" directory.

Thanks in advance.

MT4

After i installed the update and done every step over and over. Still wont work when using script.
Placing a instant order will place a pending order with all wrong nr. So somethings wrong with the PSC script

suggestion to have a auto commentary for orders

Hi Earnforex , i have a suggestion to have commentary for each trade based on symbol and time.

something like "EURUSD BUY 1 - 1.1.2022" , "EURUSD BUY 2 - 1.1.2022" and so on , for each day it numbers each buy or sell position(or if numbering each trade is not possible it could be a random number so trades can be differentiable from each other ). that would be really cool for journal and analyzing trades.

hope that make sense and possible to do.

Thank you

Please consider making the account balance editable

Hi, thank you for the wonderful indicator.

Please make the account balance to based on the user's input instead of just grabbing it automatically. Or better yet, maybe a button to switch between automatically getting and manually inputing the account balance.

Having to go to additional funds every time to add the difference between accounts is not convenient and really slows things down. Especially when you are working with multiple charts and you need to quickly take trades.

Once again, thank you for the indicator.

Consider setting Pound Averaging feature for Position Sizer in both MT4 & MT5 versions?

Hi. Great work as always... I hv been a huge fan and user of Position Size Calculator since few years ago with the one using PSC Script to quickly put in a trade. This new Position Sizer is amazing. Kudos to the Team in its further development.

I have a suggestion... One which I believe if can be implemented will be a game changer for Position Sizer EA. I have been trading lately using the Pound Averaging Strategy used by big boys taught by my mentor. What this does is to open multiple PO POS (position) at various prices but all with the same SL. So, e.g. if I decided to execute a netting strategy with 5 Sell Limit POS because price is playing out based on my strategy parameters. The very 1st POS I set either an instant or Sell Stop to trigger the 1st order for me to be in play. As I believe there would be a retrace before moving forward to my intended analysis, I will then set Sell Limit orders. So, the next 5 Sell Limit POs I would like to input POS 1 at 1.0000, POS 2 at 1.0010, POS 3 at 1.0020, POS 4 at 1.0030 and POS 5 at 1.0040 with all these 5 Pending Orders are with the same SL value. However, with the TP I would like to have options to have all TP value of each POS the same price value (OR)..., manually/by pulling the line on the chart to set each POS differently. Meaning e.g. POS 1 the TP set at 0.9980, POS 2 the TP set at 0.9980, POS 3 the TP set at 0.9960, POS 4 the TP set at 0.9940 and POS 5 the TP set at 0.9940

Pound averaging strategy ensures that I have a better price when price goes against initially but still keeping the same SL value of each POS. So, on the last POS essentially I'm risking a smaller SL amt but when price goes in favour, my 5th, 4th and 3rd POS will start amassing more pips and better returns than the 2nd and 1st POS. If for whatever reasons price stalls and doesn't go beyond my 1st POS I can close all the POS' with still a sizeable +ve TP amount. This is in itself controlling my risk management with a smarter approach. But if price does go in my favour puncturing through POS 1 then I'm in good profit for all 6 POS' and just wait till price hits the already set individual TP values for each of the 5 POS'.

So..., that's what I see can be a wonderful feature if the Pound Averaging feature can be coded into Position Sizer EA. I'm not sure if it could be done (as I'm a noob in coding, and thus I leave it to you to see if it can be done?) but if it can..., this definitely is a game changer in my eyes as I've learnt this from my mentor and it's a wonderful strategy that has shown superb results. We're all trading using this strategy to maximise profits when it works out and if it doesn't by going against, we're still able to manage our funds at the end, coming out with +ve returns.

I hope you see the value in such a feature and if this could be done and added into Position Sizer EA in the next update I am sure it will be a biggie for everyone to enjoy :) Anyway, you're the expert and let me know how this goes... Can it be done and is it useful... Cheers

New feature request: Break even by percentage

It'd be nice to have the option to insert a break even by percentage.
We could type de percentage, for instance, 50%, and when the price hits 50% fo the TP the SL is moved to break even.
Thanks.

Add option to refresh Stop loss automatically

Hello,

It would be great if we can add an option to automatically refresh the stop loss value (following the stop loss in points entered in the settings)

the issue is that I have to click on the stop loss to refresh the value because entering a trade.
I would prefer the stop loss to refresh automatically.

When setting stop loss in the settings to 100 points for example. I would like it to move like the entry.

Example with SL = 100 points (Long position)

  • Entry price is: 1.9048
  • SL: 1.9038

Price is moving down to 1.9045 on the next tick

  • Entry price is now: 1.9045
  • I would like SL to be automatically: 1.9035

Suggestion:
Add an option to refresh automatically the stop loss on each tick

NZDCHF Wrong Position Sizes

On NZDCHF for FundingTalent's demo server this is giving me the wrong position sizes. i.e. it is giving me 600 & 1200 lot size suggestions which is way more than possible.. Any tips on debugging what might be giving the wrong data?

Breakeven Option

Has there been discussion on adding a breakeven option, such as when price hits TP, move SL 3 pips above entry, or move SL to reaction point? Thanks for your consideration.

Chris

Some suggestions for the UI

Hi, I have some suggestions:

(1) For the textfields marked by red circle below:

image

Could you make the textfield values auto-calculated when users are typing on the textfields? Currently I have to press Enter or switching the textfield focus (by pressing TAB key or clicking other textfield) to trigger the calculation, so if the values can be calculated automatically, it will be more convenient.

(2) Shows pips/points difference information between the SL/TP & Entry price on the main window.

Commodities and stock not position sized with risk.

POS bug

Sorry for no voice. Forgot i could say something hehe.
Okay what the problem is that with commodeties and stock the POS dosnt correct the position size. As you can se with the 3 examples. I show also in last example with FX pairs it works just fine. But every commodity and stock it wont calculate the position size to the risk.

TP levels based on symbols on a chart with symbol changer indicator

Hi , thanks for this great free indicator you provided for us, can i please request to add a feature to adjust TP levels according to different symbols? right now if you change the symbol on the current chart the TP levels remain on price levels of previous symbol.

cheers

Issue With MT4 Version of calculator

Hello I don't how but, when apply your indicator the graphic don't show me all price, in the contrarian manner it shows shortly
I Attach a Screenshot.

In the image you can see in price don't showing last pip and the pipete
Captura
l

And in a new chart without your indicator price showing correctly
Captura1

It's how if the indicator expands the chart to the right into the MT4
And my congrats is a powerfull too

Compile Error!

Hi,
I want to chnage something and add some other features to this awesome tools. But when I compile at first time (without any change) I get this compile error!

image

How can I fix this?

Not possible to have 0 as default SL to disable initial SL line

I am not able to save the config that I have no initial SL line. When I set the value of (SL: Default stop-loss value) to 0 and save the template, the next time I load the chart I have a SL line again. When I set a value to 100 it is saved correctly and applies on every chart with the correct value, just saving 0 to disable it does not work.

Another problem that I have is: when I manully override the default calculated SL on the main tab to 0 to get rid of the SL line I can not run the PSC Script since it returns a warning: Stop-Loss Line not found!

I would really appreciate to know how to trade without initial SL line.

I use latest v2.39.

Enhancement automatic trading book

Hello. Sorry for my bad entglish, i hope it's understandable for you.

I had the idea to write the content of the message to a csv file, to have something like a trading documentation, example here:

Commentary,DateTime,Period,Symbol,Order,Size,Risk,Entry,SL,TP
....
1653532768,2022.05.26 02:39,16388,XAUUSD,Buy Stop,0.06,87.38,1874.21,1858.64,1905.35
1653571168,2022.05.26 13:19,16388,EURUSDc,Buy Stop,0.14,93.71,1.07833,1.07116,1.09266
1653571705,2022.05.26 13:28,16388,EURUSDc,Buy Stop,0.7,467.00,1.08194,1.07477,1.09627
....

that works fine.
Now want to hide the dialog of the PositionSizeCalculator per code in script.
So that it is not visible when using ChartScreenShot.
Is that possible?
regards Eduard

一键挂单

您好,PositionSize中如果默认挂单线设在前一根蜡烛高低点就更棒了。也就是以孕线形式的蜡烛突破高低点设buystop或sellstop挂单线,止损线设在孕线另一边。buystop挂单:孕线蜡烛上方+2点+点差,止损在孕线下方-2点;sellstop挂单:孕线蜡烛下方-2点,止损在孕线上方+2点+点差。如果默认挂单线能这样设置,将极大方便快速突破交易的挂单。请老师参考一下,谢谢!

Conflict with PriceAlert Panel

Hi,
This is an excellent tool as is PriceAlert Panel. Unfortunately, when I use both in the same chart, it seems they interfeere with each other in a negative way.

When they are both in the same chart,, if I then change the timeframe, usually one of them fails the initialization (-1) and is removed. If I have a Price Alert set, usually PriceAlert is the one removed.

Sometimes there is also interference with the indicator popup windows.

I'm using MT4 build 1340 on Windows 7.
PriceAlert version is 1.03.
PositionSizeCalculator version is 2.39.

Jaime

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.