Making a 1D array/vector from a table

Hello,
I have this table or a 2D array
I want to seperate the numbers from the first column which have zero values in the third column. So in the end my result would be
x = [0; 0.0242; 0.3403]
Does anyone knows how it can be done ?

 採用された回答

Ive J
Ive J 2021 年 1 月 23 日
編集済み: Ive J 2021 年 1 月 23 日

1 投票

X = cell2mat(X_cell); % X_cell: your original cell
myVec = X(X(:, 3) == 0, 1);

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeShifting and Sorting Matrices についてさらに検索

製品

リリース

R2019a

質問済み:

2021 年 1 月 23 日

編集済み:

2021 年 1 月 23 日

Community Treasure Hunt

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

Start Hunting!

Translated by