Support Board
Date/Time: Wed, 30 Apr 2025 20:23:57 +0000
Post From: Code optimization
[2021-09-11 22:58:38] |
ertrader - Posts: 682 |
The attached code works as expected, compiles with the latest SC and works without issue. It is designed to take a trade signal from another study and initiate a short (-1) or long (1), then disable until re-enabled with a button push. There are some conditions (1-4) that work fine. It uses custom study buttons for enable/disable, short/long enable/disable etc. It all works ok. The only issue I have is performance. Something about the code is inefficient. I believe it has to do with the custom study button code (rows 249-355) This code should have refresh times less than 5 ms IMO as it is not very complicated and relatively short. In studies, the MS refresh time is anywhere from 40-200 MS and more if I add more data. If anyone has recommendations on more efficient code, please let me know! Date Time Of Last Edit: 2021-09-11 23:08:06
|
![]() ![]() ![]() |