<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[Forex Software — How to Force "Do Not Exit" Strategy in Express Generator]]></title>
		<link>https://forexsb.com/forum/topic/9795/how-to-force-do-not-exit-strategy-in-express-generator/</link>
		<atom:link href="https://forexsb.com/forum/feed/rss/topic/9795/" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in How to Force "Do Not Exit" Strategy in Express Generator.]]></description>
		<lastBuildDate>Thu, 22 Aug 2024 11:45:00 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: How to Force "Do Not Exit" Strategy in Express Generator]]></title>
			<link>https://forexsb.com/forum/post/80956/#p80956</link>
			<description><![CDATA[<p>Let me know</p>]]></description>
			<author><![CDATA[null@example.com (iamgreatest)]]></author>
			<pubDate>Thu, 22 Aug 2024 11:45:00 +0000</pubDate>
			<guid>https://forexsb.com/forum/post/80956/#p80956</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to Force "Do Not Exit" Strategy in Express Generator]]></title>
			<link>https://forexsb.com/forum/post/80944/#p80944</link>
			<description><![CDATA[<p>Well, in my case it generates several random strategies and saves it as not to leave and all I do after that is to make a single test again </p><p>Today I&#039;m going to try your way, let&#039;s see if it literally already generates with the not coming out</p>]]></description>
			<author><![CDATA[null@example.com (gabdecsters)]]></author>
			<pubDate>Wed, 21 Aug 2024 10:17:58 +0000</pubDate>
			<guid>https://forexsb.com/forum/post/80944/#p80944</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to Force "Do Not Exit" Strategy in Express Generator]]></title>
			<link>https://forexsb.com/forum/post/80939/#p80939</link>
			<description><![CDATA[<p>Hey gabdecsters,<br />Seeing your efforts encouraged me to dive into the codebase and I found a very simple fix. </p><p>Follow the steps and 100% of strats generated will have exit indicator as &quot;Do not exit&quot; and hence useful for SL and TP.<br />1] Open file:- bin/lib/xgen.min.js</p><p>2] Find in the file:- t.openOnlyNames=[&quot;Entry Time&quot;,&quot;Long or Short&quot;,&quot;Pin Bar&quot;]</p><p>3] Replace it with:- t.openOnlyNames = [&quot;Accelerator Oscillator&quot;, &quot;Accumulation Distribution&quot;, &quot;ADX&quot;, &quot;Alligator&quot;, &quot;Average True Range&quot;, &quot;Awesome Oscillator&quot;, &quot;Bears Power&quot;, &quot;Bollinger Bands&quot;, &quot;Bulls Power&quot;, &quot;Candle Color&quot;, &quot;Commodity Channel Index&quot;, &quot;DeMarker&quot;, &quot;Directional Indicators&quot;, &quot;Donchian Channel&quot;, &quot;Entry Time&quot;, &quot;Envelopes&quot;, &quot;Force Index&quot;, &quot;Long or Short&quot;, &quot;MACD&quot;, &quot;MACD Signal&quot;, &quot;Momentum&quot;, &quot;Money Flow Index&quot;, &quot;Moving Average&quot;, &quot;Moving Average of Oscillator&quot;, &quot;Moving Averages Crossover&quot;, &quot;On Balance Volume&quot;, &quot;Pin Bar&quot;, &quot;RSI&quot;, &quot;RVI&quot;, &quot;RVI Signal&quot;, &quot;Standard Deviation&quot;, &quot;Stochastic&quot;, &quot;Stochastic Signal&quot;, &quot;Volumes&quot;, &quot;Williams&#039; Percent Range&quot;]</p><p>4] Save and don&#039;t forget to use --max_exit_slots 1 --ind_exit_time false</p><p>5] Enjoy !</p>]]></description>
			<author><![CDATA[null@example.com (iamgreatest)]]></author>
			<pubDate>Wed, 21 Aug 2024 07:20:50 +0000</pubDate>
			<guid>https://forexsb.com/forum/post/80939/#p80939</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to Force "Do Not Exit" Strategy in Express Generator]]></title>
			<link>https://forexsb.com/forum/post/80793/#p80793</link>
			<description><![CDATA[<p>I&#039;m without. Sleeping since yesterday I managed to speed up countless jobs after that</p>]]></description>
			<author><![CDATA[null@example.com (gabdecsters)]]></author>
			<pubDate>Sun, 04 Aug 2024 02:59:05 +0000</pubDate>
			<guid>https://forexsb.com/forum/post/80793/#p80793</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to Force "Do Not Exit" Strategy in Express Generator]]></title>
			<link>https://forexsb.com/forum/post/80791/#p80791</link>
			<description><![CDATA[<p>Wow thanks great work.</p>]]></description>
			<author><![CDATA[null@example.com (iamgreatest)]]></author>
			<pubDate>Sun, 04 Aug 2024 02:47:35 +0000</pubDate>
			<guid>https://forexsb.com/forum/post/80791/#p80791</guid>
		</item>
		<item>
			<title><![CDATA[How to Force "Do Not Exit" Strategy in Express Generator]]></title>
			<link>https://forexsb.com/forum/post/80789/#p80789</link>
			<description><![CDATA[<p>After months of effort, I&#039;ve finally found a solution to a common problem many users face with the Express Generator. While we can&#039;t directly create strategies that only exit with TP and Stop Loss, we can modify how these strategies are saved. Here&#039;s a step-by-step guide to achieve this:<br />Open the file bin/lib/collection.js.<br />Locate the serializeCollection function. This function is responsible for converting strategies to the format saved in the JSON file.<br />Inside this function, find the part where strategies are mapped. It should look similar to:</p><div class="codebox"><pre><code>return collectionRecords.map((rec) =&gt; {
    // ... other code ...
    strategy: {
        properties: {
            // ... properties ...
        },
        openFilters: rec.strategy.entryParams.map(mapIndParam),
        closeFilters: rec.strategy.exitParams.map(mapIndParam),
        timeUpdated: rec.strategy.timeUpdated,
    },
    // ... other code ...
});</code></pre></div><br /><p>Modify the closeFilters part to always use the &quot;Do not Exit&quot; indicator. Replace the line:</p><p>closeFilters: rec.strategy.exitParams.map(mapIndParam),</p><p>subscrube foir </p><div class="codebox"><pre><code>closeFilters: [{
    name: &#039;Do not Exit&#039;,
    listIndexes: [0],
    numValues: []
}],</code></pre></div><p>5. Save the file after making these changes.<br />These modifications will ensure that all strategies are saved with the &quot;Do not Exit&quot; indicator as the only exit indicator, regardless of how they were originally generated.<br />Note: This change only affects how strategies are saved, not how they&#039;re generated or tested. For the generator to use only &quot;Do not Exit&quot; during generation and testing, additional changes to other files would be necessary, which only Popov can implement.<br />After making these changes, all your strategies will be generated with no exit. You should then perform a single test again using the Express Generator as a validator, or even optimize it, because by default, the &quot;Do not Exit&quot; will always be included, and it won&#039;t close positions prematurely before reaching TP or Stop Loss.<br />Another observation: in your .ini configuration file, it&#039;s necessary to set only one slot for closing operations as the default.<br />I sincerely hope this tutorial has made you as happy as it has made me. While it&#039;s not the ideal solution we&#039;d prefer, consider this: if you generated 1 million strategies using Express and they were saved with these modifications, after performing a single test, you&#039;d be left with 700,000 strategies. That&#039;s only a 30% reduction, which is truly remarkable as it doesn&#039;t make such a significant difference.<br />Trade safely, everyone!</p>]]></description>
			<author><![CDATA[null@example.com (gabdecsters)]]></author>
			<pubDate>Sat, 03 Aug 2024 06:41:37 +0000</pubDate>
			<guid>https://forexsb.com/forum/post/80789/#p80789</guid>
		</item>
	</channel>
</rss>
