Problem using interp1 with a sharp change in the data
8 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Jaime De La Mota Sanchis
el 18 de Nov. de 2019
Comentada: Jaime De La Mota Sanchis
el 18 de Nov. de 2019
Hello everyone.
I have a vector of data and I want to interpolate it using interp1. The problem is that there is a sharp increase in the values of the vector and the resulting graph does not reproduce the data propperly.
Is there a way to make the interpolated data reproduce the sharp jump propperly?
I will attach a figure where my issue is displayed.
Any answer is appreciated.
Thank you very much.
Jaime.
5 comentarios
Mil Shastri
el 18 de Nov. de 2019
Thanks for clarification. What will also help is a clear description of what you want the output to look like.
Respuestas (1)
Steven Lord
el 18 de Nov. de 2019
Try using ischange to detect these sharp changes in your data and interpolating using only data in the same "piece" of your curve (where pieces are delimited by the ends of your data sets and the change points) as the points for which you want the interpolated value.
0 comentarios
Ver también
Categorías
Más información sobre Interpolation en Help Center y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!