フィルターのクリア

Brush 4colums data

2 ビュー (過去 30 日間)
Mohamed Madian
Mohamed Madian 2019 年 9 月 29 日
回答済み: Pranjal Kaura 2021 年 7 月 28 日
Hello everybody:
I have a GUI that draw data using only two colums which are long. and lat..
However the origional data I use are four colums (Lat, Long, Date, and Force).
I Want to brush the data and save all 4 colums after brushing in one matrix. I usually use the righ mouse and save the variable after brushing ??
I apprechiate if somebody can Help with This ??

回答 (1 件)

Pranjal Kaura
Pranjal Kaura 2021 年 7 月 28 日
Hey Mohamed,
It is my understanding that you want to use the brushing tool on the GUI which was plotted using only 2 columns of a matrix(say X). Now you want to save ALL the entries(All columns) in matrix X, corresponding to the exported brushed data.
I.e. you want to select certain entries from column 'Long' and 'Lat' by using the brushing tool on your plot, and further want to extract all the columns from matrix X corresponding to the saved brush entries.
To select data from plots you can use the brush tool. The selected data can then be exported to the workspace. Refer the documentation to know more.
Here's the code snippet to perform further computation
% X is the Inital Matrix || Bdata is the matrix exported through brush selection || C is the Required Matrix
for i = 1:size(X, 1)
if any(X(i, 1:2) == Bdata)
C(end + 1, :) = X(i, :);
end
end

カテゴリ

Help Center および File ExchangeDescriptive Statistics and Visualization についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by