mirror of
https://github.com/freqtrade/frequi.git
synced 2024-11-26 21:15:15 +00:00
parent
c8517939e0
commit
b1266bd4f6
|
@ -79,6 +79,7 @@ import {
|
|||
formatPercent,
|
||||
formatPrice,
|
||||
humanizeDurationFromSeconds,
|
||||
isNotUndefined,
|
||||
} from '@/shared/formatters';
|
||||
import { TableField, TableItem } from 'bootstrap-vue-next';
|
||||
|
||||
|
@ -115,6 +116,10 @@ const worstPair = computed((): string => {
|
|||
return `${value.pair} ${formatPercent(value.profit_ratio, 2)}`;
|
||||
});
|
||||
|
||||
const pairSummary = computed(() => {
|
||||
return props.backtestResult.results_per_pair[props.backtestResult.results_per_pair.length - 1];
|
||||
});
|
||||
|
||||
const backtestResultStats = computed(() => {
|
||||
// Transpose Result into readable format
|
||||
const shortMetrics =
|
||||
|
@ -198,14 +203,19 @@ const backtestResultStats = computed(() => {
|
|||
|
||||
{
|
||||
metric: 'Win/Draw/Loss',
|
||||
value: `${
|
||||
props.backtestResult.results_per_pair[props.backtestResult.results_per_pair.length - 1].wins
|
||||
} / ${
|
||||
props.backtestResult.results_per_pair[props.backtestResult.results_per_pair.length - 1]
|
||||
.draws
|
||||
} / ${
|
||||
props.backtestResult.results_per_pair[props.backtestResult.results_per_pair.length - 1]
|
||||
.losses
|
||||
value: `${pairSummary.value.wins} / ${pairSummary.value.draws} / ${
|
||||
pairSummary.value.losses
|
||||
} ${
|
||||
isNotUndefined(pairSummary.value.winrate)
|
||||
? '(WR: ' +
|
||||
formatPercent(
|
||||
props.backtestResult.results_per_pair[
|
||||
props.backtestResult.results_per_pair.length - 1
|
||||
].winrate ?? 0,
|
||||
2,
|
||||
) +
|
||||
')'
|
||||
: ''
|
||||
}`,
|
||||
},
|
||||
{
|
||||
|
|
|
@ -32,6 +32,7 @@ export interface PairResult {
|
|||
profit_total: number;
|
||||
trades: number;
|
||||
wins: number;
|
||||
winrate?: number;
|
||||
}
|
||||
|
||||
export interface ExitReasonResults {
|
||||
|
@ -48,6 +49,7 @@ export interface ExitReasonResults {
|
|||
profit_total_pct: number;
|
||||
trades: number;
|
||||
wins: number;
|
||||
winrate?: number;
|
||||
}
|
||||
|
||||
// Generated by https://quicktype.io
|
||||
|
@ -59,6 +61,7 @@ export interface PeriodicStat {
|
|||
wins: number;
|
||||
draws: number;
|
||||
loses: number;
|
||||
winrate?: number;
|
||||
}
|
||||
|
||||
export interface PeriodicBreakdown {
|
||||
|
|
Loading…
Reference in New Issue
Block a user