[]
        
(Showing Draft Content)

재무 차트(FinancialChart)의 재무 지표

wijmo.chart.finance.analytics 모듈에는 기술 인디케이터(indicator), 오버레이 및 Fibonacci 도구를 포함한 재무 차트에 대한 분석 확장 기능이 포함되어 있습니다.

기술 지표는 기존 데이터 세트에 하나 이상의 공식을 적용하여 계산되는 파생된 데이터 세트입니다. 기술 지표는 일반적으로 자산의 시장 방향을 예측하는 데 사용되며, 일반적으로 Y축 눈금이 다르기 때문에 원본 데이터와 별도로 표시됩니다.

지원되는 지표 유형:

  • Average True Range (ATR): 자산의 변동성을 측정하는 데 사용됩니다. Average true range(ATR)는 가격 추세가 아닌 가격 변동성의 정도를 나타냅니다.
  • Relative Strength Index (RSI): 모멘텀 오실레이터(momentum oscillator)는 최근 거래 기간의 종가를 기준으로, 자산의 현재와 과거 강점 또는 약점를 측정하기 위해 고안되었습니다.
  • Commodity Channel Index (CCI): 특정 기간 동안의 평균 가격 수준에 비해 상대적인 자산의 현재 가격 수준을 측정하는 오실레이터입니다.
  • Williams %R: 빠른 스토캐스틱 오실레이터(Stochastic)와 반대인 모멘텀 지표입니다. Williams %R 지표는 자산이 거래 범위의 상한 또는 하한 부근에서 거래되고 있는지를 판단하기 위해 고안되었습니다.
  • Moving Average Convergence/Divergence (MACD): MACD 지표는 자산 가격 추세의 강도, 방향, 모멘텀, 지속 기간에서의 변화를 나타내도록 설계되었습니다.
  • Moving Average Convergence/Divergence Histogram
  • Stochastic: 스토캐스틱 오실레이터는 자산의 종가를 고가 범위와 비교하여 가격 전환점을 예측을 위해 설계된 모멘텀 지표입니다.

기술 인디케이터(indicator) 추가 방법

기술 인디케이터(indicator)는 일반 계열(Series) 클래스를 확장하여 선택한 데이터와 매개변수를 기반으로 계산된 계열을 제공합니다.

아래의 단계에 따라 차트에 추세선을 추가하실 수 있습니다:

  1. 하나 이상의 인디케이터(indicator) 객체를 만듭니다.
  2. 예를 들어 binding, bindingXstyle 속성을 설정하여 일반 계열(Series)와 같이 인디케이터(indicator)를 구성합니다.
  3. 인디케이터(indicator)의 period 속성을 설정하여 계산 기간을 결정합니다.
  4. 일부 인디케이터(indicator) 유형에는 둘 이상의 주기 매개변수가 있습니다.

Average True Range 예시

ATR 인디케이터(indicator)는 높음, 낮음, 열기,닫기 바인딩 값을 예상합니다. 일반적으로 Average True Range는 14개 기간을 기준으로 하며 일중, 일별, 주별 또는 월별 기준으로 계산할 수 있습니다.

import * as chart from '@grapecity/wijmo.chart';
import * as fChart from '@grapecity/wijmo.chart.finance';
import * as fChartAnalytics from '@grapecity/wijmo.chart.finance.analytics';

var myFinancialChart = new fChart.FinancialChart('#myFinancialChart');
myFinancialChart.bindingX = 'date';

// create ATR indicator and add it to the Chart series collection
var atr = new fChartAnalytics.ATR();
atr.binding = 'high,low,open,close';
atr.style = { stroke: 'green', strokeWidth: 2 };
atr.name = 'Average True Range'; // name in legend
atr.period = 14;
atr.visibility = 'Visible';
myFinancialChart.series.push(atr);

Relative Strength Index 예시

RSI 인디케이터(indicator)는 단일 값 바인딩을 예상합니다. period 속성은 스무딩(smoothing) 기간을 나타냅니다. 권장 스무딩(smoothing) 기간은 14입니다.

var myFinancialChart = new fChart.FinancialChart('#myFinancialChart');
myFinancialChart.bindingX = 'date';

// create RSI indicator and add it to the Chart series collection
var rsi = new fChartAnalytics.RSI();
rsi.binding = 'close';
rsi.style = { stroke: 'green', strokeWidth: 2 };
rsi.name = 'Relative Strength Index'; // name in legend
rsi.period = 14;
rsi.visibility = 'Visible';
myFinancialChart.series.push(rsi);

Commodity Channel Index 예시

CCI 인디케이터(indicator)는 높음, 낮음, 열기,닫기 바인딩 값을 예상합니다.

var myFinancialChart = new fChart.FinancialChart('#myFinancialChart');
myFinancialChart.bindingX = 'date';

// create CCI indicator and add it to the Chart series collection
var cci = new fChartAnalytics.CCI();
cci.binding = 'high,low,open,close';
cci.style = { stroke: 'green', strokeWidth: 2 };
cci.name = 'Commodity Channel Index'; // name in legend
cci.period = 20;
cci.visibility = 'Visible';
myFinancialChart.series.push(cci);

Williams %R 예시

WilliamsR 인디케이터(indicator)는 높음, 낮음, 열기,닫기 바인딩 값을 예상합니다. Williams %R의 권장 기간은 14로, 일, 주, 월 또는 일중 기간이 될 수 있습니다.

var myFinancialChart = new fChart.FinancialChart('#myFinancialChart');
myFinancialChart.bindingX = 'date';

// create Williams%R indicator and add it to the Chart series collection
var williamsR = new fChartAnalytics.WilliamsR();
williamsR.binding = 'high,low,open,close';
williamsR.style = { stroke: 'green', strokeWidth: 2 };
williamsR.name = 'Williams %R'; // name in legend
williamsR.period = 14;
williamsR.visibility = 'Visible';
myFinancialChart.series.push(williamsR);

MACD & MACD Histogram 예시

MacdMacdHistogram 인디케이터(indicator)는 단일 값 바인딩을 예상합니다. moving average convergence/divergence 인디케이터(indicator)는 세 가지 주기를 사용합니다: 느림, 빠름, 신호 평활화. MACD에 사용되는 기본 설정은 26주기 저속 EMA(지수 이동 평균)과 12주기 고속 EMA입니다. 신호 라인은 일반적으로 9주기 표시기의 이동 평균으로 설정됩니다.

이 예시에서는 MacdHistogram 인디케이터(indicator)도 추가됩니다.

var myFinancialChart = new fChart.FinancialChart('#myFinancialChart');
myFinancialChart.bindingX = 'date';

// create MACD indicator and add it to the Chart series collection
var mac = new fChartAnalytics.Macd();
mac.binding = 'close';
mac.style = { stroke: 'green', strokeWidth: 2 };
mac.name = 'MACD, Signal'; // name in legend
mac.smoothingPeriod = 9;
mac.fastPeriod = 12;
mac.slowPeriod = 26;
mac.visibility = 'Visible';
myFinancialChart.series.push(mac);

// create MACD histogram and add it to the Chart series collection
var mach = new fChartAnalytics.MacdHistogram();
mach.binding = 'close';
mach.style = { stroke: 'purple', strokeWidth: 2 };
mach.name = 'MACD Histogram'; // name in legend
mach.smoothingPeriod = 9;
mach.fastPeriod = 12;
mach.slowPeriod = 26;
mach.visibility = 'Visible';
myFinancialChart.series.push(mach);

Stochastic 예시

Stochastic 인디케이터(indicator)는 높음, 낮음, 시작 및 닫기 바인딩 값을 예상합니다. Stochastic 인디케이터(indicator)는 K 주기, D 주기, 스무딩(Smoothing) 주기의 세 가지 주기를 사용합니다.

var myFinancialChart = new fChart.FinancialChart('#myFinancialChart');
myFinancialChart.bindingX = 'date';

// create Williams%R indicator and add it to the Chart series collection
var stoch = new fChartAnalytics.Stochastic();
stoch.binding = 'high,low,open,close';
stoch.style = { stroke: 'green', strokeWidth: 2 };
stoch.name = '%K,%D'; // name in legend
stoch.dPeriod = 3;
stoch.kPeriod = 14;
stoch.smoothingPeriod = 1;
stoch.visibility = 'Visible';
myFinancialChart.series.push(stoch);

인디케이터(Indicator) 표시 옵션

visibility 속성을 다음 중 하나로 설정하여 표시기가 범례에 항목의 표시 여부를 선택할 수 있습니다:

  • Visible: 계열(Series)은 플롯과 범례에 표시됩니다.
  • Plot: 계열(Series)은 플롯에서만 볼 수 있습니다.
  • Legend: 계열(Series)은 범례에서만 볼 수 있습니다.
  • Hidden: 계열(Series)이 숨겨져 있습니다.

범례 텍스트는 인디케이터(indicator) 계열(Series)의 name 속성을 사용하여 설정됩니다.