Commit a1a43e6c authored by denis's avatar denis

project rename

parent 7e2762a8
Pipeline #126464357 passed with stage
in 1 minute and 26 seconds
.kdev4
ichinscratchy
ichi_reloaded.kdev4
otrasys
OTraSys.kdev4
ichinscratchy.conf
otrasys.conf
testsymbols.conf
ichinscratchy.confBACKTEST
symbols.conf
backtest.conf
backtestsymbols.conf
......
#################################################
# Config file for main program otrasys #
# example file- remove '.EXAMPLE' from filename #
# to use it, fit to your needs #
# #
# comments start with #, in line #
# comments are allowed #
#################################################
###############################################################################
# General Settings
###############################################################################
CONFIG_SYMBOLFILE = symbols.conf # file that holds symbols
ACCOUNT_CURRENCY = EUR # atm EUR/USD/JPY
ACCOUNT_CURRENCY_DIGITS = 2 # nr of significant digits
TRANSACTION_COSTS_FIX = 15 # fixed amount fee in account currency
TRANSACTION_COSTS_PERCENTAGE = 0.0025 # fee as percentage of position´s value
###############################################################################
# Database related settings
###############################################################################
DB_HOSTNAME = 123.123.123.123
DB_USERNAME = youruser
DB_PASSWORD = yourpassword
DB_NAME = yourdatabasename
#DB_PORT =
#DB_SOCKET =
#DB_FLAGS =
###############################################################################
# terminal output settings
###############################################################################
TERMINAL_EVAL_RESULT = none # text, html, none
TERMINAL_STATISTICS = none # text, none
###############################################################################
# General indicator settings
###############################################################################
INDI_DAYS_TO_UPDATE = 200 # default 200
INDI_ADX_PERIOD = 14 # number of periods in ADX' EMAs, default: 14
###############################################################################
# Ichimoku related settings
###############################################################################
ICHI_DAYS_TO_ANALYZE = 40 # default 40
ICHI_PERIOD_SHORT = 9 # default 9
ICHI_PERIOD_MID = 26 # default 26
ICHI_PERIOD_LONG = 52 # default: 52
ICHI_CHIKOU_CONFIRM = true # use chikou span as confirmation/filter for
# trend (default true)
ICHI_KUMO_CONFIRM = true # check whether Kumo breakout is higher/lower
# than last reaction high/low
ICHI_EXECUTION_SENKOU_X = true # execute Signal Senkou Cross, default true
ICHI_EXECUTION_KIJUN_X = true # execute Signal Kijun Cross, default true
ICHI_EXECUTION_CHIKOU_X = true # execute Chikou Cross, default true
ICHI_EXECUTION_TK_X = true # execute Tenkan/Kijun Cross, default true
ICHI_EXECUTION_KUMOBREAK = true # execute Kumo breakout, default true
###############################################################################
# Signal execution settings
###############################################################################
SIGNAL_REGIME_FILTER = ADX # Market regime filter: ADX, TNI,none (default)
SIGNAL_REGIME_ADX_THRESH = 30 # ADX market filter threshold, default 30
SIGNAL_DAYS_TO_EXECUTE = 5 # how many days backwards should signals in
# database be considered? default 5
SIGNAL_EXECUTION_DATE=real_date # when to execute signal:
# signal_date (date when signal was triggered),
# real_date (date when program is run)
SIGNAL_MANUAL_CONFIRM = true # true: confirm execution of signals (default);
# false: auto buy/sell
SIGNAL_EXECUTION_PYRAMID= none # pyramid buy/sell signals, e.g. buy more than
# 1 position in same direction?
# none: buy max 1 position in long/short,
# daily: execute only 1 long/ 1 short per day,
# pyramid on consecutive days, full: do not
# impose any limits, buy every single signal
SIGNAL_EXECUTION_WEAK = false # default false
SIGNAL_EXECUTION_NEUTRAL= false # default false
SIGNAL_EXECUTION_STRONG = true # default true
SIGNAL_EXECUTION_LONG = true # default true
SIGNAL_EXECUTION_SHORT = true # default true
SIGNAL_EXECUTION_SUNDAYS =false # execute signals that occur on Sundays? (can
# happen when pulling in futures quotes)
###############################################################################
# Portfolio related settings
###############################################################################
PORTFOLIO_ALLOCATION = equal # Model to perform portfolio allocation:
# equal (equal position sizes),
# kelly (use Kelly criterion)
PORTFOLIO_RETURNS_PERIOD = 50 # period for which mean returns are calulated
PORTFOLIO_RETURNS_UPDATE = 25 # update mean returns every X periods
###############################################################################
# Stop Loss settings
###############################################################################
SL_TYPE = percentage # percentage (percentage stop, default),
# chandelier (Chandelier Stop)
SL_PERCENTAGE_RISK = 0.02 # percent for SL_TYPE= percentage, default 0.02
SL_CHANDELIER_ATR_FACTOR = 3 # SL_TYPE=chandelier: Place SL x-times the ATR
# away (default 3)
SL_CHANDELIER_ATR_PERIOD = 26 # SL_TYPE=chandelier: Period for Averaging the
# True Range (default 26)
SL_ADJUST = trailing # fixed (use initial SL only),
# trailing (adjust SL in trend direction only)
# updown (adjust SL in both directions),
# default: trailing
SL_SAVE_DB = false # save all SL records in mysql database? (true/false)
###############################################################################
# Risk management settings
###############################################################################
STARTING_BALANCE = 10000 # starting account balance at begin of
# backtest/live trading
RISK_PER_POSITION = 0.02 # Risk of a new position in % of current
# balance + risk free Equity
POS_SIZE_CAP = 0.1 # new positions: cap size to x% of current
# balance + risk free Equity
RISK_FREE_RATE = 0.02 # rate of returns for 0 risk investment
###############################################################################
# Chart related settings
###############################################################################
CHART_PLOT = true # plot the chart, true/false
CHART_PLOT_WEAK = false # plot weak signals; default false
CHART_PLOT_NEUTRAL = false # plot neutral signals; default false
CHART_PLOT_STRONG = true # plot strong signals; default true
CHART_COLORSCHEME = contrast # light/ contrast
CHART_DAYS_TO_PLOT = 120 # default: 120
#eof
......@@ -19,10 +19,10 @@
*/
/**
* @file ichinscratchy.c
* @brief main program file of ichinscratchy trading system framework
* @file main.c
* @brief main program file of OTraSys- the trading system framework
*
* This is the main file of the ichinscratchy trading system framework, which
* This is the main file of OTraSys- the trading system framework, which
* contains main(). It reads the command line options, establishes the
* connection to the mysql database, updates the quotes and indicators and
* calls the routines that check for buy signals and execute them.
......@@ -121,7 +121,7 @@ int main (int argc, char **argv)
bool orderbook_only = false; // just print out orderbook
bool account_only = false; // just prinnt out account info
bstring configfile_name = bfromcstr("./config/ichinscratchy.conf");
bstring configfile_name = bfromcstr("./config/otrasys.conf");
extern int optind, opterr, optopt;
extern char *optarg;
......@@ -169,23 +169,25 @@ int main (int argc, char **argv)
fprintf(stdout, "\nUsing config file %s\n", bdata(configfile_name));
break;
case 'V': // --version
fprintf(stdout, "\nICHINSCRATCHY v%i.%i.%i%s\n", MAJOR_VERSION_NR, RELEASE_NR,SUB_RELEASE_NR,SUBRELEASE_SUFFIX);
fprintf(stdout, "\nOTraSys- the Open Trading System Framework v%i.%i.%i%s\n", MAJOR_VERSION_NR, RELEASE_NR,SUB_RELEASE_NR,SUBRELEASE_SUFFIX);
fprintf(stdout, "An open source framework to create trading systems\n");
fprintf(stdout, "\nplease visit https://spare-time-trading.de\n\n");
return 0;
break;
case 'v': // --verbose
verbose_flag = true;
fprintf(stdout, "\nICHINSCRATCHY v%i.%i.%i%s", MAJOR_VERSION_NR, RELEASE_NR,SUB_RELEASE_NR,SUBRELEASE_SUFFIX);
fprintf(stdout, "\nOTraSys v%i.%i.%i%s", MAJOR_VERSION_NR, RELEASE_NR,SUB_RELEASE_NR,SUBRELEASE_SUFFIX);
fprintf(stdout, "\nVerbose flag (-v, --verbose) set)\n");
break;
case '?': // --help
fprintf(stdout, "\nUsage:");
fprintf(stdout, "\nichinscratchy [OPTION]");
fprintf(stdout, "\n\nICHINSCRATCHY: Trading System Framework");
fprintf(stdout, "\nOTraSys- the open Trading System Framework");
fprintf(stdout, " v%i.%i.%i%s", MAJOR_VERSION_NR, RELEASE_NR,SUB_RELEASE_NR,SUBRELEASE_SUFFIX);
fprintf(stdout, "\nAn open source framework to create trading systems");
fprintf(stdout, "\n\nUsage:");
fprintf(stdout, "\notrasys [OPTION]");
fprintf(stdout, "\n\nOPTIONS:");
fprintf(stdout, "\n -?, --help \t\t\tThis help page");
fprintf(stdout, "\n -c, --configfile\t\tselect configfile within /config (default is /config/ichinscratchy.conf)");
fprintf(stdout, "\n -c, --configfile\t\tselect configfile within /config (default is /config/otrasys.conf)");
fprintf(stdout, "\n -V, --version\t\t\tshows version number");
fprintf(stdout, "\n -s, --setup_db\t\tsetup necessary database (db is cleared if exists), root password needed!");
fprintf(stdout, "\n\t\t\t\t(Note that this option is exclusive to the other command line options)");
......
......@@ -40,7 +40,6 @@
#include "bstrlib.h"
#define MAXLEN 80
//#define CONFIG_FILE "./config/ichinscratchy.conf"
/**
* @brief global configuration settings
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment