---
title: "Comment by Arnold Holm on \"Creating a Reliable EA with Custom Optimization in Metatrader 5\" | Hashnode"
description: "I would add two small boundary checks before using this score. With zero trades, the win-rate division happens before the rejection condition, so return before"
url: "https://hashnode.com/posts/creating-a-reliable-ea-with-custom-optimization-in-metatrader-5-1/681f2fcdda00b9d702d383d8/comment/6ad633308c5f7b3129e627cf"
---

[Discussion](https://hashnode.com/posts/creating-a-reliable-ea-with-custom-optimization-in-metatrader-5-1/681f2fcdda00b9d702d383d8)

Comment [Creating a Reliable EA with Custom Optimization in Metatrader 5](https://hashnode.com/posts/creating-a-reliable-ea-with-custom-optimization-in-metatrader-5-1/681f2fcdda00b9d702d383d8)

[Arnold Holm](https://hashnode.com/@stratcorealpha)

[Oct 19](https://hashnode.com/posts/creating-a-reliable-ea-with-custom-optimization-in-metatrader-5-1/681f2fcdda00b9d702d383d8/comment/6ad633308c5f7b3129e627cf)

I would add two small boundary checks before using this score. With zero trades, the win-rate division happens before the rejection condition, so return before that division. Also, a rejected run scores zero while an accepted run can score below zero. That can put a rejected run above a valid one. Give rejected runs a value below every accepted score, and keep the score and thresholds frozen for the test on later, untouched data. A combined score still needs that separate check.
