Why is the 'rfinterp1' function creating a jagged line between data points?
Mostrar comentarios más antiguos
I have an S-parameter object for which I am plotting the parameter values. I want to draw a line connecting the data points using linear interpolation. However, when I use the function 'rfinterp1', I see a jagged line instead of a linear one as shown below. Why is this happening?

Example script:
>> y = rfparam(sobj_raw_s4p, 2, 1);
>> x = sobj_raw_s4p.Frequencies;
>> xnew = f_s4p;
>> ynew = interp1(x, y, xnew);
>> figure; hold on; plot(x, db(abs(y)), 'o'); plot(xnew, db(abs(ynew)), '-'); hold off
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Interpolation en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!