Commit Graph

6220 Commits

Author SHA1 Message Date
Matthias 24a1d5a96f Change default hyperopt-name to be shorter 2021-05-12 19:06:13 +02:00
Matthias 3cbe40875d read hyperopt results from pickle or json 2021-05-12 06:06:30 +02:00
Matthias 06bf1aa274 Store epochs as json per line 2021-05-12 05:58:25 +02:00
Matthias 7398ea88e0 Change optimize_reports to convert dates to string earlier 2021-05-11 20:37:49 +02:00
Matthias b81f24d9c6
Merge pull request #4851 from rokups/rk/backtest-dataprovider
Data provider support in backtesting
2021-05-10 19:11:05 +02:00
Matthias 92186d89a2 Add some changes to strategytemplate 2021-05-09 09:56:36 +02:00
Matthias 2157923aee have edge send multiple messages if necessary
closes #4519
2021-05-08 19:45:34 +02:00
Rokas Kupstys 8d8c782bd0 Slice dataframe in backtesting, preventing access to rows past current time. 2021-05-08 18:40:49 +03:00
Rokas Kupstys f1eb653545 Fix strategy protections not being loaded in backtesting. 2021-05-08 10:29:47 +03:00
Rokas Kupstys 1b01ad6f85 Make exchange parameter optional and do not use it as parameter in backtesting. 2021-05-08 10:29:47 +03:00
Matthias 4b6cd69c81 Add test for no-exchange dataprovider 2021-05-08 10:29:47 +03:00
Rokas Kupstys d344194b36 Fix dataprovider in hyperopt. 2021-05-08 10:29:47 +03:00
Rokas Kupstys 9b4f6b41a2 Use correct datetime. 2021-05-08 10:29:47 +03:00
Rokas Kupstys 6fb4d83ab3 Fix dataprovider in hyperopt. 2021-05-08 10:29:47 +03:00
Rokas Kupstys 6af4de8fe8 Remove dataframe parameter from docs. 2021-05-08 10:29:47 +03:00
Rokas Kupstys cdfa6adbe5 Store pair datafrmes in dataprovider for backtesting. 2021-05-08 10:29:47 +03:00
Rokas Kupstys dc6e702fec Pass current_time to confirm_trade_entry/confirm_trade_exit. 2021-05-08 10:29:47 +03:00
Rokas Kupstys d34da3f981 Revert "Add dataframe parameter to custom_stoploss() and custom_sell() methods."
This reverts commit 595b8735f8.

# Conflicts:
#	freqtrade/optimize/backtesting.py
#	freqtrade/strategy/interface.py
2021-05-08 10:29:47 +03:00
Matthias 513be11fd9 Fix hyperopt output
closes #4892
2021-05-07 20:23:11 +02:00
Matthias 554f5f14b6 Raise exception if no data is left 2021-05-07 06:41:15 +02:00
Matthias 4f529fe424 Don't use Arrow to get min/max backtest dates 2021-05-06 19:43:14 +02:00
Matthias 32577cc0cd
Merge pull request #4836 from bzed/telegram-locks
Telegram rpc: split too long /locks messages
2021-05-05 20:15:13 +02:00
Matthias 431cb5313f Support informative pairs in edge positioning 2021-05-05 19:58:45 +02:00
Matthias da47f4e1a4 Fix Kraken balance update error
closes #4873
2021-05-05 06:47:26 +02:00
Matthias da574e4e69 Small style fixes 2021-05-03 06:30:41 +02:00
Matthias fc110ea418 Support csv export for new and old versions 2021-05-02 20:41:45 +02:00
Matthias 303895b33e Add support for filters to new hyperopt-results 2021-05-02 20:07:22 +02:00
Matthias 287b43e999 Output strategy results including non-optimized parameters 2021-05-02 11:30:53 +02:00
Matthias d069ad43d8 Small reformatting in hyperopt 2021-05-02 11:01:26 +02:00
Matthias 8ee0b0d8e8 Store not optimized parameters (if applicable) 2021-05-02 10:46:04 +02:00
Matthias 9049d6b779 Reformat hyper to cache parameters 2021-05-02 10:45:21 +02:00
Matthias 46f0f66039 Keep dimensions stored in hyperopt class
There is no point in regenerating them and it will cause some
overhead as all space classes will be recreated for every epoch.
2021-05-02 09:48:37 +02:00
Matthias ced5cc7ce2 Don't recalculate min/max date - they won't change between epochs 2021-05-02 09:46:27 +02:00
Matthias ecdfb6e5ed Fix output of % for new format 2021-05-02 09:46:27 +02:00
Matthias 881cba336a Show backtesting result in hyperopt-show 2021-05-02 09:46:27 +02:00
Matthias 420e75af65 Extract show_backtest_result for one strategy 2021-05-02 09:46:27 +02:00
Matthias 97478abb9d Move format explanation string to HyperoptTools 2021-05-02 09:46:27 +02:00
Matthias f2e182002d Simplify calling backtesting by returning the proper result 2021-05-02 09:46:27 +02:00
Matthias e2e1d34828 Extract stake_currency param from hyperopt-explanationstring 2021-05-02 09:46:27 +02:00
Matthias 6aaaad29d7 Use backtesting output for hyperopt results 2021-05-02 09:46:27 +02:00
Matthias 545cba7fd8 Refactor optimize_report
we should not calculate non-daily statistics in the daily stats method
2021-05-02 09:46:27 +02:00
Matthias 9994fce577 Extract generation of report for one strategy to it's own method 2021-05-02 09:46:27 +02:00
Matthias b125c975c7 Rename strategy_comparison method 2021-05-02 09:46:27 +02:00
Matthias ac2e1eb3d7 Don't import joblib for regular strategies 2021-05-02 08:44:16 +02:00
Matthias 0e359dcb7a
Merge pull request #4788 from saeedrss/develop
fetch live data from hitbtc exchange #4778
2021-05-01 19:13:00 +02:00
Matthias bdd0184f0b Small stylistic fixes 2021-05-01 17:44:43 +02:00
Matthias 1cb430f59b Remove encoding specifics, gitattributes to echeckout as utf8 2021-05-01 17:41:40 +02:00
Matthias 0b280a59bc Support per exchange params for OHLCV endpoint 2021-05-01 17:29:53 +02:00
Matthias e0ca3c014c Don't completely remove encode/decode 2021-05-01 17:12:48 +02:00
Matthias 30da307d13 Remove encode/decode for hyperopt 2021-05-01 17:01:52 +02:00
Matthias 555262b6e1 Only calculate additional indicators if the space is selected 2021-05-01 16:40:29 +02:00
Matthias e381df9098 extract has_space to Hyperopt-Tools 2021-05-01 16:36:35 +02:00
Matthias e050ea8dfa Don't load parameters for other space 2021-05-01 16:21:59 +02:00
Matthias 401f31e86b
Merge pull request #4841 from JoeSchr/fix/istrategy-return-value
fix IStrategy: abstract methods still need to pass through return value
2021-04-30 20:13:11 +02:00
Matthias 856b65206b Reduce log-frequency of AgeFilter
closes #4840
2021-04-30 19:42:41 +02:00
Joe Schr f3388ed9aa fix IStrategy: abstract methods still need to pass through return value
otherwise doing something like:
```py
dataframe = super().populate_indicators(dataframe, ...)
```

won't work, because `dataframe` becomes `None`.

This is needed if one of those methods uses dataframe.copy() instead of
just working on reference. e.g. using `merge_informative` in
`populate_indicator` in a nested class hierarchy
2021-04-30 14:39:01 +02:00
Antreas Gribas cf03daa0fd Fix bug in running hyperopt in windows 10
with preferred encoding in locale differrent from
utf-8
2021-04-30 00:28:42 +03:00
Bernd Zeimetz 3be7bc509c Telegram: send locks as chunks of 25.
Producing easily readable messages, hopefully always below the message lenght limit
2021-04-29 22:21:04 +02:00
Bernd Zeimetz 4d1613a432 Add chunks function.
Implementing a generator to split Lists into chunks.
2021-04-29 22:21:04 +02:00
Matthias a3d2e68312
Merge pull request #4750 from rokups/rk/custom_sell
Add IStrategy.custom_sell method which allows per-trade sell signal evaluation
2021-04-29 06:50:56 +02:00
Matthias aab020c9a2
Merge pull request #4818 from freqtrade/cleanup_models
Move static Trade functions to right class
2021-04-28 21:18:55 +02:00
Matthias 7c8a367442 Update docs to not promote stoploss / take-profit 2021-04-28 20:36:06 +02:00
Matthias 63c28b6519 Remove obsolete get_balance method 2021-04-28 16:00:12 +02:00
Matthias 6eb947ae09 Move static Trade functions to right class 2021-04-28 06:37:40 +02:00
Matthias 55faa6a84a safe_wrapper should use kwargs to call methods 2021-04-26 20:18:03 +02:00
Matthias 2061162d79 Convert trade-opendate to python datetime 2021-04-26 20:01:13 +02:00
Matthias dbf33271b5 Small doc changes 2021-04-26 19:52:26 +02:00
Matthias 3f84c37a79 Fix wallet calls
closes #4810  #4812
2021-04-26 14:12:52 +02:00
Rokas Kupstys 31a2285eac Fix mypy complaints. 2021-04-26 10:42:24 +03:00
Matthias bb7ef2f804 Cache pairlist in pairlist, not globally
closes #4797 closes #4689
2021-04-25 20:10:47 +02:00
Matthias 7448a05f15 Use correct variable in pairlist_manager 2021-04-25 11:01:04 +02:00
Matthias fd3afdc230 plot-profit should use absolute values 2021-04-25 10:10:09 +02:00
Rokas Kupstys 98f6fce2ec Use correct sell reason in case of custom sell reason. 2021-04-25 09:48:40 +03:00
Rokas Kupstys 595b8735f8 Add dataframe parameter to custom_stoploss() and custom_sell() methods. 2021-04-25 09:48:40 +03:00
Rokas Kupstys 961b38636f Remove explicit sell_flag parameter from SellCheckTuple. 2021-04-25 09:48:40 +03:00
Rokas Kupstys bfad4e82ad Make execute_sell() use SellCheckTuple for sell reason. 2021-04-25 09:48:40 +03:00
Rokas Kupstys a90e795695 Warn and trim custom sell reason if it is too long. 2021-04-25 09:48:40 +03:00
Rokas Kupstys 1aad128d85 Support returning a string from custom_sell() and have it recorded as custom sell reason. 2021-04-25 09:48:40 +03:00
Rokas Kupstys 1292e08fe4 Use strategy_safe_wrapper() when calling custom_sell(). 2021-04-25 09:48:40 +03:00
Rokas Kupstys 0fd68aee51 Add IStrategy.custom_sell method which allows per-trade sell signal evaluation. 2021-04-25 09:48:40 +03:00
wr0ngc0degen 869a45a031
Merge pull request #2 from freqtrade/develop
update develop from base repo
2021-04-25 05:50:03 +02:00
wr0ngc0degen 2eda25426f
fix typo in sample_strategy.py
fix copy-paste issue in populate_sell_trend docstring
2021-04-25 05:47:59 +02:00
Matthias e855530483 hdf5 handler should include the end-date 2021-04-24 20:26:37 +02:00
Matthias cb86c90d3e Remove obsolete TODO's 2021-04-24 19:16:54 +02:00
Matthias 88f26971fa Use defaultdict for backtesting 2021-04-24 19:15:09 +02:00
Matthias 8e85b63b3d
Merge pull request #4792 from JoeSchr/add-distribution-graph-to-example-notebook
add distribution graph to example notebook
2021-04-24 16:14:48 +02:00
Matthias f12e002686
Merge pull request #4775 from freqtrade/fix_wallet_unlimited
Fix wallet unlimited
2021-04-24 15:54:06 +02:00
Joe Schr 31b0e3b5e8 add distribution graph to example notebook 2021-04-24 13:29:59 +02:00
Matthias 90476c4287 Add "range" property to IntParameter 2021-04-24 07:00:33 +02:00
Matthias 9dc7f776d9 Improve log output when loading parameters 2021-04-23 20:35:30 +02:00
saeedrss 37d8e3c758 Merge branch 'develop' of https://github.com/freqtrade/freqtrade into develop 2021-04-23 22:28:33 +04:30
Matthias 191a31db30 NameErrors should not stop loading a different strategy 2021-04-23 19:36:26 +02:00
Matthias df16fbd742 Add "dataload complete" message to backtest + hyperopt 2021-04-23 19:22:41 +02:00
saeedrss b69a9134f5 fixing support for HitBTC #4778
hitbtc by default send candle from beginning (not most recently)
this change fixed
2021-04-23 21:27:13 +04:30
Matthias 4005708f85 Handle edge with volumepairlist and empty pair_whitelist
closes #4779
2021-04-23 06:50:39 +02:00
Matthias 406c1267a2 Remove superfluss space 2021-04-22 20:01:08 +02:00
Matthias f5f0bf53af
Merge pull request #4780 from rokups/rk/new-pairs-days
Add --new-pairs-days parameter for download-data command.
2021-04-22 19:55:25 +02:00
Matthias ccaf5764da Small adjustments 2021-04-22 19:41:01 +02:00
Matthias 0d2457cd47 Add lock_reason to per-pair lock 2021-04-22 19:28:50 +02:00
Matthias f2d5f476d4
Merge pull request #4777 from c0d5x/informative-global-pairlock-msg
Add the reason why there is a global pairlock when lock is available
2021-04-22 19:24:13 +02:00
Matthias 4693cba10d
Merge pull request #4769 from freqtrade/trades_pagination
Trades pagination
2021-04-22 19:13:19 +02:00
Matthias 7e2e196643 improve sell_message by using sell rate 2021-04-22 17:13:22 +02:00
Rokas Kupstys 3144185409 Allow specifying "new_pairs_days" in config. 2021-04-22 11:18:28 +03:00
Matthias f744df2374 Fix bad fill message 2021-04-22 10:01:41 +02:00
Rokas Kupstys 09efa7b06b Add --new-pairs-days parameter for download-data command.
This parameter allows us to customize a number of days we would like to download for new pairs only. This allows us to achieve efficient data update, downloading all data for new pairs and only missing data for existing pairs. To do that use `freqtrade download-data --new-pairs-days=3650` (not specifying `--days` or `--timerange` causes freqtrade to download only missing data for existing pairs).
2021-04-22 10:07:13 +03:00
Matthias 515c73f399 Don't hard-limit trades endpoint for now 2021-04-22 06:51:26 +02:00
Jose Hidalgo 896ec58cad Add the reason why there is a global pairlock when lock is available 2021-04-21 15:02:33 -06:00
Matthias d8c8a8d8c2 Remvoe pointless arguments from get_trade_stake_amount 2021-04-21 20:01:10 +02:00
Matthias ba2d4d4656 Reduce number of calls to `Trade.total_open_traes_stakes()` 2021-04-21 19:27:42 +02:00
Matthias 0233aa248e Limit stake_amount to max available amount 2021-04-21 17:22:16 +02:00
Matthias 9f6f3e0862 Address ZeroDivisionExceptiond
closes #4764 closes #4617
2021-04-20 21:41:49 +02:00
Matthias bd92ce938c trade_history should paginate through results
this avoids huge results
2021-04-20 21:04:44 +02:00
Matthias b230558294
Merge pull request #4766 from freqtrade/fill_rpc
Add buy/sell fill messages to telegram
2021-04-20 20:39:15 +02:00
Matthias cfa9315e2a Prevent out of candle ROI sells 2021-04-20 20:29:53 +02:00
Jose Hidalgo fd110c7d62 The error that it prints says the contrary to what
was evaluated.

ex. Trading stopped due to Max Drawdown 0.79 < 0.2 within 48 candles
2021-04-20 11:50:53 -06:00
Matthias f821ef5aec Final finetunings of rpc_fill messages 2021-04-20 19:36:30 +02:00
Matthias d740aae8ca Default fill notifications to off 2021-04-20 19:23:29 +02:00
Matthias 0341ac5a55 rename RPC message types 2021-04-20 19:23:28 +02:00
Matthias 8800a09770 Don't send double-notifications for stoploss fills 2021-04-20 19:22:14 +02:00
Matthias fecd5c582b Add buy and sell fill notifications
closes #3542
2021-04-20 19:22:14 +02:00
Matthias 06d6f9ac41 Fix calculation of unlimited_stake in case of modified wallet 2021-04-20 15:55:48 +02:00
Matthias a2acb54e7e Clarify comments in pairlist 2021-04-19 15:15:40 +02:00
Matthias 44bfb53668 Don't use current rate for closed trades 2021-04-17 19:29:34 +02:00
Matthias 1eb9ce4227 Allow specifying pairs for optimize commands via `--pairs` 2021-04-17 10:47:32 +02:00
Matthias c52edcff4d
Merge pull request #4677 from mads03dk/get_trade
Add API endpoint for getting a specific trade
2021-04-16 19:57:58 +02:00
Matthias 9f2b6ee9a5
Merge pull request #4740 from freqtrade/decimal_stoploss_Hyperopt
stoploss and roi skdecimal spaces hyperopt
2021-04-16 19:46:07 +02:00
Matthias aeb81f90ff Implement errorhandling for /trade endpoint 2021-04-16 19:35:56 +02:00
Gonzalo Matheu 7a98de10ea telegram: Formatting typings 2021-04-15 21:51:16 -03:00
Gonzalo Matheu e3c5a4b3fc telegram: Formatting imports 2021-04-15 21:51:16 -03:00
Gonzalo Matheu 5fae4ea2fd telegram: Formatting code 2021-04-15 21:51:16 -03:00
Gonzalo Matheu 50bdae8eb2 telegram: Adding forcebuy inline keyboard 2021-04-15 21:51:16 -03:00
Gonzalo Matheu e2f28991e6 telegram: Wrapping long line 2021-04-15 21:51:16 -03:00
Gonzalo Matheu 271e4500d9 telegram: Adding dynamic keyboard to /forcebuy response 2021-04-15 21:51:16 -03:00
grillzoo 5e51ba6258 fix flake8 2021-04-15 21:38:00 +01:00
Matthias ce870bbcf7 Use 3 decimals for ROI space 2021-04-15 21:38:20 +02:00
Théo Martin fa343b0484
Fix get_min_pair_stake_amount formula 2021-04-15 01:19:30 +01:00
Matthias 52c482cecf Convert trailing and roi defaults to skdecimal 2021-04-14 20:36:34 +02:00
Matthias e820814809 Default-stoploss-hyperopt should use decimal space, nto real 2021-04-14 20:32:34 +02:00
Matthias ba38e398e4 Add type hint 2021-04-13 22:17:42 +02:00
Matthias c2f35ce416 /balance should use cached tickers when possible 2021-04-13 20:21:03 +02:00
Matthias 82d66410f7 Fix /performance output
if multiple messages are necessary

closes #4726
2021-04-13 19:20:57 +02:00
Matthias e4bb6b1582 Add kucoin exchange subclass
Kucoin has some specific orderbook restrictions

closes #4723
2021-04-13 12:28:07 +02:00
Matthias 37c8fd6ad7 Remove arrow from models.py 2021-04-13 11:55:03 +02:00
Matthias 59cfbbee17
Merge pull request #4724 from csteeg/develop
Fixes FTX stoploss on echange throwing an error
2021-04-13 08:41:52 +02:00
Matthias 9b23be4021 Return a copy from `current_whitelist`
this avoids manipulating of the pair whitelist from within a strategy
2021-04-13 06:49:53 +02:00
Matthias 4b902d6eb8 Don't use response-model on trades endpoint for now 2021-04-13 06:23:11 +02:00
Matthias 9a58a85347 Don't export "hum" date versions for trade objects.
They are not used and have a rather high performance penalty due to
using arrow.get
2021-04-13 06:17:11 +02:00
Matthias cb60db01b1
Merge pull request #4703 from freqtrade/decimal_space
Add SKDecimal Space
2021-04-12 19:18:10 +02:00
Chris van de Steeg d4dc05980c
Update ftx.py
Stoploss price should be set as param instead of passing it as price according to ccxt
2021-04-12 16:01:46 +02:00
Matthias be0dc737dc
Merge pull request #4706 from freqtrade/simplify_fiat_convert
Simplify fiat convert and fix USD coingecko problem
2021-04-10 14:57:34 +02:00