Giter Club home page Giter Club logo

freqtrade-configs's Introduction

My Freqtrade strategies and config

How to optimise parameter

# install python3.9-dev and pip if not avaliable
sudo apt install python3.9-dev
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python3.9 get-pip.py

# clone repo
git clone -b develop https://github.com/freqtrade/freqtrade.git
cd freqtrade

# setup and activate env
./setup.sh --install
source .env/bin/activate

# create profile
freqtrade new-config --config user_data/config.json

# change config pairs manual
# download data
freqtrade download-data --exchange binance -t 5m --days 500

# use hyperopt to optimise strategy parameters by buy and sell signal
# read this for the loss function https://www.freqtrade.io/en/stable/hyperopt/#loss-functions
freqtrade hyperopt --hyperopt-loss SharpeHyperOptLoss --spaces buy sell --timerange 20210101- --timeframe 5m --strategy BelieveInCoin

# update parameters to default config inside strategy python file

# use hyperopt to optimise roi and trailing configs parameters
freqtrade hyperopt --hyperopt-loss OnlyProfitHyperOptLoss --spaces roi trailing --timerange 20210101- --timeframe 5m --strategy BelieveInCoin

# update minimal_roi and trailing_stop to config

# backtesting
freqtrade backtesting --timeframe 5m --strategy BelieveInCoin 

# or compare list
freqtrade backtesting --timeframe 5m --timerange 20210301- --strategy-list BelieveInCoin NostalgiaForInfinityX

# plot backtest
freqtrade plot-dataframe --strategy BelieveInCoin --timerange=20210701-

How to run (docker)

mkdir ft_userdata
cd ft_userdata/
# Download the docker-compose file from the repository
curl https://raw.githubusercontent.com/freqtrade/freqtrade/stable/docker-compose.yml -o docker-compose.yml

# Pull the freqtrade image
docker-compose pull

# Create user directory structure
docker-compose run --rm freqtrade create-userdir --userdir user_data

# Create configuration - Requires answering interactive questions
docker-compose run --rm freqtrade new-config --config user_data/config.json

# add credential and configs
# add strategies
# edit docker-compose.yml CMD to change strategy

# run via docker-compose
docker-compose up -d

Configs

Using minimal roi

example: "12": 0.064 mean after 12 mins holding if the profit positive more than 6.4% will automatic sell

but for testing no minimal_roi is probably the best

"minimal_roi": {
    "0": 0.16,
    "21": 0.037,
    "64": 0.012,
    "178": 0
}

Trailing stop

"trailing_stop": true,
"trailing_stop_positive": 0.079,
"trailing_stop_positive_offset": 0.156,
"trailing_only_offset_is_reached": true

Pair list

use docker-compose run freqtrade test-pairlist to check the pairlist

ref https://www.freqtrade.io/en/stable/includes/pairlists/

Example volume pair list

"exchange": {
    "pair_whitelist": [],
    "pair_blacklist": [
        ".*BEAR/BTC",
        ".*BULL/BTC",
        ".*UP/BTC",
        ".*DOWN/BTC",
        ".*HEDGE/BTC",
    ]
},
"pairlists": [
    {
        "method": "VolumePairList",
        "number_assets": 20,
        "sort_key": "quoteVolume"
    },
    {"method": "AgeFilter", "min_days_listed": 7},
    {
        "method": "RangeStabilityFilter",
        "lookback_days": 10,
        "min_rate_of_change": 0.01,
        "refresh_period": 1440
    },
    {"method": "ShuffleFilter"}
],

freqtrade-configs's People

Contributors

ntsd avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

freqtrade-configs's Issues

freqtrade download-data -t 5m 15m 1h 4h 1d --days 500

Hi Ntsd,

just a small hint you can use:
freqtrade download-data -t 5m 15m 1h 4h 1d --days 500

for timeframe in '5m' '15m' '1h' '4h' '1d'; do
freqtrade download-data --exchange binance -t $timeframe --days 500
done

best regards

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.