how to plot graph from text data as shown in the image

 Respuesta aceptada

KALYAN ACHARJYA
KALYAN ACHARJYA el 6 de Mzo. de 2021
Editada: KALYAN ACHARJYA el 6 de Mzo. de 2021
Try this way in MATLAB edit window
%Load the file
A=readmatrix('file.txt');
Get the x and y values
x=A(:,1);
x=A(:,2);
Plot the x and y data
plot(x,y);
Before plotting make sure the lengths of x and y are the same length, if not the same length, then check the data arrangement format within the text file.

Más respuestas (0)

Categorías

Más información sobre 2-D and 3-D Plots en Centro de ayuda y File Exchange.

Preguntada:

el 6 de Mzo. de 2021

Editada:

el 6 de Mzo. de 2021

Community Treasure Hunt

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

Start Hunting!

Translated by