mirror of
https://github.com/freqtrade/frequi.git
synced 2024-11-11 02:33:51 +00:00
Use Total profit for open cumprofit calcs
This commit is contained in:
parent
f374939890
commit
f598a631a5
|
@ -58,7 +58,10 @@ const settingsStore = useSettingsStore();
|
|||
const chart = ref<typeof ECharts>();
|
||||
|
||||
const openProfit = computed<number>(() => {
|
||||
return props.openTrades.reduce((a, v) => a + v[props.profitColumn], 0);
|
||||
return props.openTrades.reduce(
|
||||
(a, v) => a + (v['total_profit_abs'] ?? v[props.profitColumn] ?? 0),
|
||||
0,
|
||||
);
|
||||
});
|
||||
|
||||
const cumulativeData = computed<CumProfitChartData[]>(() => {
|
||||
|
|
|
@ -11,12 +11,7 @@ defineProps({
|
|||
<template>
|
||||
<div class="text-center flex-fill mt-2 d-flex flex-column">
|
||||
<TradesLogChart :trades="trades" class="trades-log" />
|
||||
<CumProfitChart
|
||||
:trades="trades"
|
||||
profit-column="profit_abs"
|
||||
class="cum-profit"
|
||||
:show-title="true"
|
||||
/>
|
||||
<CumProfitChart :trades="trades" class="cum-profit" :show-title="true" />
|
||||
<hr />
|
||||
<ProfitDistributionChart class="mt-3" :trades="trades" :show-title="true" />
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue
Block a user