2
Follow
3
Followers
Tính toán đúng trong mô phỏng js nhưng sai trong tính toán thực tế
Created 2019-05-30 10:35:09
2
1692
Tôi có một tính toán: data.lastprice là giá bán, changeprice_sell là giá thay đổi, data.avgprice là giá trung bình.
Mục đích của tính toán này là tìm ra giá trị tối đa của giá giao dịch + giá trị thay đổi so với giá trung bình + giá trị thay đổi.
Đây là mã:
nextsell = _N(Math.max(data.lastprice + changeprice_sell, data.avgprice + changeprice_sell),2);
nextsell là biến cục bộ trong hàm, đối tượng dữ liệu và changeprice_sell là biến toàn cầu, trong đó changeprice_sell có thể được sửa đổi theo thời gian thực thông qua mẫu tương tác

Vấn đề hiện nay là: Simulation hoạt động, NextSell tính toán đúng.

Hình ảnh trên ổ cứng của tôi không đúng.

Related Recommendations
Get Started with FMZ Quant PlatformSECURITY BUGI keep getting error: Exchange_GetAccount: Invalid ContractTypeWe have an incredibly profitable market making algorithm for sideways markets on Bitmex - but need expert to help eliminate wait times during downward volatility in the marketError with deribitLimitations of the backtesting engineHow to install ta-lib on linux docker?5.5 Trading strategy optimization5.4 Why do we need an off-sample test5.3 How to read the strategy backtest performance report

