how to make the contour line more curvy

1 visualización (últimos 30 días)
yuxuan
yuxuan el 10 de Mzo. de 2024
Comentada: Mathieu NOE el 26 de Abr. de 2024
The contour line is straight, how to make it more curvy? I have uploaded the image i and raw data.
  2 comentarios
DGM
DGM el 10 de Mzo. de 2024
It's not clear how your data is arranged or whether this is even the same data or all that's required to plot it. There's only one 63x189 matrix in the file.
Neither 63 nor 189 are integer-divisible by 12, so it's hard to guess whether this needs to be reshaped. It doesn't look like it does. So how did you plot this? If there's other information needed, please include it.
yuxuan
yuxuan el 11 de Mzo. de 2024
sorry, i have uploaded the wrong data. Here's the correct data.

Iniciar sesión para comentar.

Respuestas (1)

VBBV
VBBV el 10 de Mzo. de 2024
Editada: VBBV el 10 de Mzo. de 2024
xdata % your x data
ydata % your y data
zdata % your z data
v = min(min(zdata)):1:max(max(zdata)) % add finer step size for smoother /curvier lines
contourf(xdata,ydata,zdata,v) % use additional argument
  3 comentarios
VBBV
VBBV el 10 de Mzo. de 2024
Editada: VBBV el 10 de Mzo. de 2024

From the figure attachment the data looked like it's sufficiently smoothed, but was plotted at a coarse step. Yes, if the data is coarsely spaced that option doesn't smooth as you told.

@yuxuan , you can try this function to make the lines more curvy given in this link.

https://www.mathworks.com/help/matlab/ref/smoothdata.html

Iniciar sesión para comentar.

Categorías

Más información sobre Contour Plots en Help Center y File Exchange.

Productos


Versión

R2020b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by