Choose one question to test
Write down the question before running the test.
The idea
A useful test starts with a specific question.
“Does this work?” could mean many things. Name what the program sees and what you will check afterward.
A small example
For our moving-average project:
When the latest price is above its three-price average, what happens to the next price?
This is a question about a price change. It is not yet a claim that a trade would make money.
Try it
Write four lines:
- Input: the latest three prices.
- Measurement: latest price minus their average.
- Outcome: next price minus latest price.
- Comparison: examine all eligible observations as a baseline.
Keep the meaning of “next” consistent with the way prices are sampled.
Check your work
The measurement uses the present and past. The outcome uses a later observation.
If you change the question after seeing the answer, record that change. It becomes a new test, not an invisible improvement to the old one.