u33m2ha8
 ( 0.00% )
- ago
Good evening again.

Here are some questions about how I can incorporate various trading instructions into one block:

1. A trade should be closed if the closing price is below the 200-day simple moving average (SMA) for more than two days.

2. A trade should be closed if the price has risen by more than 25% in a single day, meaning today's closing price > yesterday's closing price * 1.25.

3. Number of closing prices over the last 2500 days.

4. Trading volume (currency) greater than 20 million per day on average over the last 21 trading days.

Thank you.
0
38
Solved
4 Replies

Reply

Bookmark

Sort
Glitch8
 ( 10.87% )
- ago
#1
1. A trade should be closed if the closing price is below the 200-day simple moving average (SMA) for more than two days.
- Indicator Compare to Indicator (Close < SMA200)
- Add the Qualifier for N Consecutive Days (2)

2. A trade should be closed if the price has risen by more than 25% in a single day, meaning today's closing price > yesterday's closing price * 1.25.
- Indicator Compare to Value (ROC(1) > 25)

3. Number of closing prices over the last 2500 days.
- ? I don't understand this one

4. Trading volume (currency) greater than 20 million per day on average over the last 21 trading days.
- SMA(Volume,20) > 20,000,000
0
Best Answer
u33m2ha8
 ( 0.00% )
- ago
#2
Regarding point 3): That the stock has at least 2500 closing prices (and is therefore tradable for approximately 10 years)
0
Glitch8
 ( 10.87% )
- ago
#3
Ah ok. One way I can think of would be to test if SMA(2500) > 0
0
- ago
#4
QUOTE:
to test if SMA(2500) > 0
@Glitch
I'm reading the goal of this inquiry entirely differently than you are. I "think" the poster wants to be sure there's position turnover for every trading day for the last 10 years; 250*10=2500. But I could be wrong.

I would suggest he alternatively watches the recent trading Volume of the stock instead to make sure there's sufficient trading activity. Something like ADX(Volume,22) for an indicator might work. I do something like this for my stock screener, but I've never done anything like this for a trading strategy.
0

Reply

Bookmark

Sort