フィルターのクリア

How to group scatter plot data?

2 ビュー (過去 30 日間)
Rinu
Rinu 2013 年 10 月 24 日
I have three vectors x,y and z of the same length. How can I generate a scatter plot of x and y which is grouped according to the corresponding values of z (e.g. group 1 for z<10, group 2 for 10<=z<20 and group 3 for z>=20)? I'm thinking of using gscatter but for that I have to make a group vector first. Is there any way I can generate a vector "group" which is "1" for z<10, "2" for 10<=z<20 and "3" for z>=20? Any help is much appreciated.

回答 (0 件)

カテゴリ

Help Center および File ExchangeScatter Plots についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by