Closed emmtte closed 6 months ago
Hi @emmtte and thank you! If you want to limit the size of data per indicator, simply init the indicator with the size limit.
Example: This limits the SMA to 3 values:
const sma = new SMA(3);
There is no command to remove the first element pushed to an indicator. You can only replace
the latest value.
Sorry to bother you, but in your exemple is the 3 corresponding to a period of 3 ? I have used https://tulipindicators.org/sma and there a difference between the size of the datas with the same period to calculate the SMA. For exemple there is a different with a size of 500 compared to a size of 100 with the a period of 3 How to set period ?
Hi and thanks for this great library
A general question about all technicals indicators.
How to limit the size of data ?
Exemple, I want only add max 500 values for calculations.
How to limit this ? What is the command to remove the first element of the values ?