Skip to main content
← All updates

Strategy guide

How to turn a trading idea into rules you can test, without code

Turn “buy when the trend improves” into clear trading rules. Follow a Bitcoin example in MeritFunded, calculate the risk, and compare what happens when you change one setting.

MeritFunded

Turn a trading idea into rules you can test.

“I’ll buy Bitcoin when the trend turns up.”

It sounds straightforward until you try to act on it. Does “turns up” mean one rising candle or a week of higher prices? When do you buy, and what would make you sell?

To test the idea without code, write down the market, entry, exit and position size, then express those decisions in a visual strategy builder. In MeritFunded, that means turning an idea into a project brief, reviewing the draft’s conditions and running a backtest. The builder handles the supported rules; you decide what they should mean.

1. Give the idea a clear rule sheet

Start with a question a test could answer:

Does buying Bitcoin when a faster moving average crosses above a slower one produce useful results after costs?

A moving average smooths prices over a chosen number of periods. This example uses 20-period and 50-period simple moving averages, or SMAs, which give equal weight to each closing price. On one-hour candles, they cover 20 and 50 completed hours.

Here is the strategy we will build. Its settings are an educational example, not a recommendation.

DecisionExample rule
Market and timeframeBTC/USD, one-hour candles.
EntryBuy when a completed candle produces a fresh SMA20 crossover above SMA50, provided no position is open.
Signal exitClose when SMA20 crosses below SMA50.
ProtectionA 1% stop and 2% target, calculated from the signal candle’s closing price in this visual draft.
Position sizeAllocate 10% of current equity to an entry—the generated draft’s allocation for this example. This is position value, not the amount at risk.
ExposureLong only, one position at a time, with no adding to an existing position.

“Crosses above” means the fast average was at or below the slow one at the previous close and is above it now. “Is above” can remain true for hours. That small wording change can produce a different set of trades.

Keep the instrument and data source fixed too. A spot Bitcoin account and a test using perpetual-futures prices are different experiments, even when both are described simply as “Bitcoin.”

2. Turn the rules into conditions in MeritFunded

Open Studio and describe the idea in the AI composer. Include concrete settings rather than asking for a “profitable strategy”:

Test BTC/USD on one-hour candles. Buy when SMA 20 crosses above SMA 50. Exit on the reverse crossover, with a 1% stop and a 2% target. Hold one position at a time.

Review the project brief, confirm BTC/USD and 1H, then choose Create strategy draft. A brief records the idea; it is not yet a tested strategy.

Check the draft against your rule sheet. Starter indicators or conditions may differ from what you intended, so do not assume that describing a rule has already configured it.

In Visual builder, add two SMAs through Add indicator, with periods of 20 and 50. Set the entry condition to the faster SMA Crosses above the slower SMA. Remove unwanted conditions before deleting unused indicators.

Under Exit conditions, add the reverse: the faster SMA Crosses below the slower one. Set Strategy stop loss to 1% and Strategy take profit to 2%. Read the plain-English summary alongside your rule sheet.

MeritFunded Visual builder showing SMA periods 20 and 50, an upward crossover entry and a downward crossover exit.
The example’s two moving averages and crossover conditions in MeritFunded Visual builder.

Check sizing as well as signals. This example’s generated draft allocates 10% of equity; it does not calculate position size from a chosen loss budget. Likewise, check that any daily pause or loss limit is included in the executable rules. Mentioning it in the brief does not activate it.

Finally, distinguish signal prices from fills. This draft evaluates completed candles and submits orders for the next market event. Its stop and target are anchored to the signal close, so their distance from the eventual fill can differ.

3. Work out what one losing trade could cost

Position size and risk are different numbers. With $100,000 in simulated capital, allocating 10% creates roughly $10,000 of exposure. It does not mean losing $10,000 when a 1% stop is reached.

For a simple illustration, assume the signal close and entry are both $50,000 per BTC. A $10,000 position is 0.2 BTC, and its 1% stop is $49,500. An exact fill there produces a $100 price loss. Add a hypothetical $20 allowance for combined costs:

$100 price loss + $20 costs = $120 planned loss.

At the 2% target, a $200 price gain would leave $180 after the same allowance.

Illustrative loss at different stop distances for a fixed 0.2 BTC position, including a $20 cost allowance.
Illustrative calculation, not a backtest result or fee quote. Actual fees, spread, slippage and financing depend on the trade.

Set your risk budget before testing. For example, a personal limit of 0.5% of equity would allow $500 here, so the $120 calculation fits. A gap or worse fill can still increase the loss; recalculate as equity changes.

Set a rejection point for the strategy too—for example, a maximum drawdown of 5%. These are review criteria, not automatic controls enabled in this draft. If you later trade an evaluation account, its actual loss limits apply separately.

4. Run the test and read beyond the return

A backtest applies rules to historical prices to simulate their results. Open Backtest results → Backtest settings, choose your dates and costs, then select Run backtest.

Fix those assumptions before seeing a result. The example’s two versions use the same settings:

Test setup: 1 August–1 October 2026, dates in UTC+8; $100,000 starting capital; fees of 4 basis points per side and slippage of 2 basis points. One basis point is 0.01%. The BTC/USD screen label maps to BTCUSDT in this run, using Binance USD-M perpetual-futures price and volume data.

These are the experiment’s settings, not a universal fee schedule. Keep the full cost model in view, including financing where applicable; the $20 planning allowance above is not an input copied into the test.

When the run finishes, open Trades as well as the overview. Check whether entries, exits and costs follow the intended rules before trusting the total. Then read several measures together:

  • Net return: what remains after the run’s modeled costs.
  • Maximum drawdown: the largest fall from a previous equity peak to a subsequent low.
  • Trade count, win rate and average win/loss: whether gains cover losses and costs, or the result depends on a few outcomes.

A positive result does not establish an edge. One market period may simply suit the rules. The report also shows buy-and-hold, but this strategy allocates only 10% at entry, so the exposures are not equivalent.

Read the simulation limitations too. Candle-based models cannot establish the exact sequence of real trades within a candle or guarantee future fills. A simulated stop is not an exact loss ceiling.

5. Change one thing, then compare

Suppose a slower average might reduce repeated entries in choppy conditions. Write down that hypothesis, choose New version, and change only the slow SMA from 50 to 60. Keep the market, fast SMA, exits, position allocation and test settings fixed.

The two historical simulations produced this comparison:

MeasureSMA20 / SMA50SMA20 / SMA60
Closed trades2016
Net return0.43%0.22%
Maximum drawdown0.50%0.60%

Rounded report values for the test setup above, not expected future results.

The slower average produced fewer trades, but return fell and drawdown increased. Fewer signals did not make this version better on those measures. That is a useful answer: a change needs evidence, not just an appealing explanation.

Use Test history to compare recorded versions, periods and assumptions, and select the relevant strategy version when opening its report. Keep the original even when a change looks better.

Before testing another period, choose a version and write down what would make you reject it. Reserve history you have not used to select the rules—for example, a later period after this development window. That is out-of-sample testing. Once its results drive another adjustment, it is no longer untouched.

Repeatedly tuning until history looks perfect is overfitting: fitting noise that may not repeat. A short test helps you understand the rules; it cannot establish how they will behave across different market conditions.

A backtest does not start a bot. Saving a tested version and deploying it are separate steps. MeritFunded customer trading is simulated, and historical results do not guarantee future performance or profits.

Ready to test your own idea? Open Studio, describe the market, timeframe, entry and exit conditions, then check the generated draft.

Advertising cookies Optional ad cookies help us measure and improve our ads. Your choice never affects how you use MeritFunded.