Echo of Yesterday
Return the lag 1 autocorrelation of the series values: how strongly each value is related to the one right before it, from -1 to 1.
Example 1
values [1,2,3,4,5]
returns 0.4
A steady climb: each value is close to the one before it.
Constraints
4 <= len(values) <= 60- The values are not all equal
Write it in your browser, against the clock. The model solution, stepped through line by line, comes after.
More statsmodels problems
- Fair R SquaredEasy
- Group GapsEasy
- Is the Share DifferentEasy
- Is the Slope RealEasy
- Prices for New RowsEasy
- Range for the SlopeEasy
- Two CausesEasy
- Better of Two ModelsMedium