better analyze.sh output
This commit is contained in:
parent
bbbf58b367
commit
c1de6d9485
@ -141,7 +141,7 @@ then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
echo "OVERALL RESULT: $(cat ${g_tmp}/overall-result-* | awk "{ SUM += \$1 / ${analyzecounter} } END { printf(\"%2.2f\", SUM) }')%" | tee analyze-${analyzedate}/overall-result.log
|
echo "OVERALL RESULT: $(cat ${g_tmp}/overall-result-* | awk "{ SUM += \$1 / ${analyzecounter} } END { printf(\"%2.2f\", SUM) }")%" | tee analyze-${analyzedate}/overall-result.log
|
||||||
cat analyze-${analyzedate}/*.history.csv.log >analyze-${analyzedate}/analyze-overall.log
|
cat analyze-${analyzedate}/*.history.csv.log >analyze-${analyzedate}/analyze-overall.log
|
||||||
echo "" | tee -a analyze-${analyzedate}/overall-result.log
|
echo "" | tee -a analyze-${analyzedate}/overall-result.log
|
||||||
echo "Trades: $(grep "BUY: " analyze-${analyzedate}/analyze-overall.log | wc -l)" | tee -a analyze-${analyzedate}/overall-result.log
|
echo "Trades: $(grep "BUY: " analyze-${analyzedate}/analyze-overall.log | wc -l)" | tee -a analyze-${analyzedate}/overall-result.log
|
||||||
|
@ -96,7 +96,7 @@ ${f_BUY}"
|
|||||||
then
|
then
|
||||||
echo "BUY: ${f_echo_prefix}${f_BUY}"
|
echo "BUY: ${f_echo_prefix}${f_BUY}"
|
||||||
echo "${csv_headline}
|
echo "${csv_headline}
|
||||||
${f_last_line}" | perl -pe 's/((?<=,)|(?<=^)),/ ,/g;' | column -t -s,
|
${f_last_line}" | cut -d, -f 2-21 | perl -pe 's/((?<=,)|(?<=^)),/ ,/g;' | column -t -s,
|
||||||
echo "$f_BUY" >${g_tmp}/open-${tmpfile}
|
echo "$f_BUY" >${g_tmp}/open-${tmpfile}
|
||||||
BUY_PRICE=$current
|
BUY_PRICE=$current
|
||||||
f_BUY=""
|
f_BUY=""
|
||||||
|
@ -78,7 +78,7 @@ function check_sell_conditions {
|
|||||||
then
|
then
|
||||||
echo "SELL: $(tail -n1 ${f_ASSET_HIST_FILE} | cut -d, -f1)"
|
echo "SELL: $(tail -n1 ${f_ASSET_HIST_FILE} | cut -d, -f1)"
|
||||||
echo "${csv_headline}
|
echo "${csv_headline}
|
||||||
${f_last_line}" | perl -pe 's/((?<=,)|(?<=^)),/ ,/g;' | column -t -s,
|
${f_last_line}" | cut -d, -f 2-21 | perl -pe 's/((?<=,)|(?<=^)),/ ,/g;' | column -t -s,
|
||||||
echo "${f_SELL}"
|
echo "${f_SELL}"
|
||||||
result=$(g_percentage-diff ${BUY_PRICE} ${current})
|
result=$(g_percentage-diff ${BUY_PRICE} ${current})
|
||||||
result=$(echo "${result}-${FEE}" | bc | sed 's/^\./0./; s/^-\./-0./')
|
result=$(echo "${result}-${FEE}" | bc | sed 's/^\./0./; s/^-\./-0./')
|
||||||
|
Loading…
Reference in New Issue
Block a user