MACDIndicatorUnit

public class MACDIndicatorUnit

A single date's MACD reading — the MACD line, its signal line, and their difference, the histogram.

Shared by both MACDResponse and MACDEXTResponse: the two functions differ only in how each component's moving average is calculated, not in the shape of the reading they report.

Author

Sylvester Sefa-Yeboah

Since

1.1.0

Constructors

Link copied to clipboard
public void MACDIndicatorUnit(String date, double macdHistValue, double macdSignalValue, double macdValue)
Creates a unit.

Properties

Link copied to clipboard
public String date
The date this reading applies to.
Link copied to clipboard
public double macdHistValue
The MACD histogram: the MACD line minus its signal line.
Link copied to clipboard
public double macdSignalValue
The signal line: a moving average of the MACD line.
Link copied to clipboard
public double macdValue
The MACD line: the difference between the fast and slow moving averages.

Functions

Link copied to clipboard
public String getDate()
Returns the date this reading applies to.
Link copied to clipboard
public double getMacdHistValue()
Returns the MACD histogram value.
Link copied to clipboard
public double getMacdSignalValue()
Returns the signal line value.
Link copied to clipboard
public double getMacdValue()
Returns the MACD line value.
Link copied to clipboard
public String toString()