알림목록 백테스팅 차트에서 이동평균선, 일목균형표, 볼린저 그래프 표시
This commit is contained in:
@@ -254,8 +254,8 @@ export function buildStrategyChartIndicators(
|
||||
const MA_OVERLAY_TYPES = new Set(['SMA', 'EMA']);
|
||||
|
||||
/**
|
||||
* 투자관리 차트 탭 — 캔들 영역에 이동평균(SMA)·볼린저밴드를 기본 포함
|
||||
* (전략 조건에 없어도 표시 설정 메뉴로 표시/숨김 가능)
|
||||
* 캔들 영역 기본 오버레이 — 이동평균(SMA)·일목균형표·볼린저밴드
|
||||
* (전략에 없어도 표시, 우측 상단 토글로 표시/숨김)
|
||||
*/
|
||||
export function ensurePaperChartOverlays(
|
||||
indicators: IndicatorConfig[],
|
||||
@@ -263,6 +263,7 @@ export function ensurePaperChartOverlays(
|
||||
getVisual: GetVisual,
|
||||
): IndicatorConfig[] {
|
||||
const hasMa = indicators.some(i => MA_OVERLAY_TYPES.has(i.type));
|
||||
const hasIchimoku = indicators.some(i => i.type === 'IchimokuCloud');
|
||||
const hasBb = indicators.some(i => i.type === 'BollingerBands');
|
||||
const prepend: IndicatorConfig[] = [];
|
||||
|
||||
@@ -274,6 +275,14 @@ export function ensurePaperChartOverlays(
|
||||
);
|
||||
if (sma) prepend.push(sma);
|
||||
}
|
||||
if (!hasIchimoku) {
|
||||
const ichimoku = buildOneIndicator(
|
||||
{ dslType: 'ICHIMOKU', registryType: 'IchimokuCloud' },
|
||||
getParams,
|
||||
getVisual,
|
||||
);
|
||||
if (ichimoku) prepend.push(ichimoku);
|
||||
}
|
||||
if (!hasBb) {
|
||||
const bb = buildOneIndicator(
|
||||
{ dslType: 'BOLLINGER', registryType: 'BollingerBands' },
|
||||
|
||||
Reference in New Issue
Block a user