Coin Sorting Logic
Last updated November 4, 2024
FAQ: Coin Sorting Logic
When using the "anycoin" scanner, multiple assets may be selected. Coins are dynamically sorted depending on indicator and operation. Usually, the first condition before the action that is evaluated as TRUE sorts the entire block:
Example 1
- Rule starts at 10:00pm and conditions are evaluated
- BTC, ETH, LTC and 10 other coins have met the 3 conditions set in the above screenshot
- The first condition to be evaluated as TRUE sorts the entire block that is before the action. That is, 'MA9 crossing above price'
- The rule engine will sort the 13 coins by MA9 in descending order, which means it will select the coin with the highest MA9 first and keep sorting in descending order
- For example, if BTC has the highest MA9 increase, it will be bought first. Then if ETH has the second highest MA9 increase it will be bought second and so on
Important note: Coins are sorted in descending order for 'Crossing above', 'Increased by' and 'Greater than' conditions as the scanner sorts according to the biggest value.
Example 2
- Rule starts at 10:00pm and conditions are evaluated
- BTC, ETH, LTC and 10 other coins have all met the BUY conditions
- The first condition before the action that is evaluated as TRUE sorts the entire block that is before the action. That is, 'MA9 crossing below price'
- The rule engine will sort the 13 coins by MA9 in ascending order, which means it will select the coin with the lowest MA9 first and keep sorting in ascending order
- For example, if BTC has the lowest MA9 increase, it will be bought first. Then if ETH has the second lowest MA9 increase it will be bought next and so on
Important note: Coins are sorted in ascending order for 'Crossing below', 'Decreased by' and 'Lower than' conditions as the scanner sorts according to the lowest number.
Additionally, coins are sorted by absolute value in 'Crossing Above/Below' & 'Lower/Greater than' events.
However in cases of increase/decrease, coins are sorted based on percentage as these conditions are already using percentage growth: