mirror of
https://github.com/mihakralj/QuanTAlib.git
synced 2026-08-23 21:18:04 +00:00
Merge branch 'dev'
This commit is contained in:
@@ -14,9 +14,7 @@
|
||||
| **Signature** | [lsma_signature](lsma_signature.md) |
|
||||
|
||||
- LSMA (Least Squares Moving Average), also known as the Moving Linear Regression or Endpoint Moving Average, calculates the least squares regression...
|
||||
- Parameterized by `period`, `offset` (default 0).
|
||||
- Output range: Tracks input.
|
||||
- Requires `period` bars of warmup before first valid output (IsHot = true).
|
||||
- **Similar:** [EPMA](../epma/epma.md), [ALMA](../alma/alma.md) | **Complementary:** R-squared for regression quality | **Trading note:** Least Squares MA; linear regression value at current bar, minimizing squared deviations.
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
LSMA (Least Squares Moving Average), also known as the Moving Linear Regression or Endpoint Moving Average, calculates the least squares regression line for the preceding time periods. In plain English: it finds the "best fit" line for the data window and tells you where that line ends.
|
||||
@@ -113,4 +111,4 @@ Validated against Skender.
|
||||
|
||||
1. **Overshoot**: Because it projects a trend, LSMA will overshoot significantly when the trend reverses. It assumes the trend continues.
|
||||
2. **Offset**: You can use a positive offset to extrapolate into the future (forecasting), or a negative offset to center the average.
|
||||
3. **Noise**: It is very sensitive to outliers because it tries to fit a line to them.
|
||||
3. **Noise**: It is very sensitive to outliers because it tries to fit a line to them.
|
||||
Reference in New Issue
Block a user