Add noise to discrete time series
Ältere Kommentare anzeigen
Hi,
I have a long-term time series composed by discrete labels,the values are 1,2,3,4.
Now, I want to add noise to these time series changing in randomly position the value of the label.
I need to pass the percentage of the data to change (for ex. 5% or 10%), evaluate randomly the positions to change and change the value in the positions selected.
Example:
input: [11122323444442343211] % 20 elements
Add noise for 10 % = 2 elements...
select randomly positions of 2 elements and change the value
output: [11142323441442343211]
Thanks in advance.
Andrea
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Mathematics finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!