force minimum 15 minutes (900 seconds) timeframe fpor EMA/MACD calculations
This commit is contained in:
parent
fdadf53051
commit
436dfe602e
@ -188,6 +188,10 @@ docker compose logs -f
|
||||
|
||||
Update:
|
||||
```
|
||||
# Optinal: Remove local data
|
||||
git reset --hard HEAD^ # Remove local commits
|
||||
git clean -fd # Remove local uncommited files
|
||||
|
||||
git pull -f --all
|
||||
```
|
||||
|
||||
|
@ -8,6 +8,13 @@ function get_ema {
|
||||
|
||||
f_ema=""
|
||||
|
||||
# force minimum 15min timeframe
|
||||
if [ $(echo "${INTERVAL} < 900" | bc -l) -ne 0 ]
|
||||
then
|
||||
f_period=$(echo "${f_period}*(900/${INTERVAL})" | bc -l | sed 's/\..*//')
|
||||
g_echo "ATTENTION!!!! Period lower then 15 minutes - correcting to $f_period"
|
||||
fi
|
||||
|
||||
# calculate EMA if last EMA is given
|
||||
if [ -n "$f_last_ema" ]
|
||||
then
|
||||
|
Loading…
Reference in New Issue
Block a user