added chart

This commit is contained in:
olli 2023-10-28 17:28:22 +02:00
parent f21628cc0e
commit cd7ab2e1f9

View File

@ -48,7 +48,7 @@ function analyze {
IFS=$'\n'
# Chart Part
echo "$(head -n1 ${file}),Market Perrormance,Score,Buy Score,Sell Score" >analyze-${analyzedate}/chart-${tmpfile}
echo "$(head -n1 ${file}),Market Perrormance,Score,Buy Score,Sell Score,InTrade" >analyze-${analyzedate}/chart-${tmpfile}
# Chart Part End
for line in $(egrep "^${ANALYZE_TIME}" "$file" | grep -v ',,')
@ -82,6 +82,7 @@ function analyze {
fi
fi
# Chart Part
local f_intrade=0
local f_score=${f_buy_score}
[ -z "${f_buy_score}" ] && f_buy_score=0
if [ -z "${f_sell_score}" ]
@ -89,8 +90,9 @@ function analyze {
f_sell_score=0
else
f_score=${f_sell_score}
f_intrade=1
fi
echo "$line,${f_market_performance},${f_score},${f_buy_score},${f_sell_score}" >>analyze-${analyzedate}/chart-${tmpfile}
echo "$line,${f_market_performance},${f_score},${f_buy_score},${f_sell_score},${f_intrade}" >>analyze-${analyzedate}/chart-${tmpfile}
# Chart Part End
done
@ -195,7 +197,7 @@ do
echo "Price, EMA, Levels" >>analyze-${analyzedate}/chart-${tmpfile}.html
genchart analyze-${analyzedate}/chart-${tmpfile} 500 2,25,26,27,28,29,30,31,32,33,34,35,4,36,37,38,39 green,DarkSlateGrey,DarkSlateGrey,Gold,DarkOrange,DarkOrange,GoldenRod,GoldenRod,GoldenRod,GoldenRod,DarkOrange,DarkOrange,MidnightBlue,Indigo,DarkSlateBlue,DodgerBlue,DeepSkyBlue >>analyze-${analyzedate}/chart-${tmpfile}.html
echo "Score" >>analyze-${analyzedate}/chart-${tmpfile}.html
genchart analyze-${analyzedate}/chart-${tmpfile} 500 41,42,43 Green,DeepSkyBlue,Orange >>analyze-${analyzedate}/chart-${tmpfile}.html
genchart analyze-${analyzedate}/chart-${tmpfile} 500 41,42,43,44 Green,DeepSkyBlue,Orange,Red >>analyze-${analyzedate}/chart-${tmpfile}.html
#echo "Sell Score" >>analyze-${analyzedate}/chart-${tmpfile}.html
#genchart analyze-${analyzedate}/chart-${tmpfile} 500 42 green,blue >>analyze-${analyzedate}/chart-${tmpfile}.html
echo "MACD" >>analyze-${analyzedate}/chart-${tmpfile}.html