Graph data series with colors

Along with say hello, I am attaching a .txt, where the first column is the X axis, the second column is the Y axis, and the third column represents the magnitude.
What I need is a 2D graph of X vs Y, and with a colorbar (color scale) that represents the magnitude of the third column.
Thanks greetings.

回答(1 个)

load data.txt
scatter(data(:,1), data(:,2), [], data(:,3), 'filled'); colorbar;

类别

帮助中心File Exchange 中查找有关 Graph and Network Algorithms 的更多信息

提问:

ibt
2021-7-27

回答:

2021-7-28

Community Treasure Hunt

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

Start Hunting!

Translated by