フィルターのクリア

HOw do i find indices of 'NAN' rows in excel raw file in matlab?

3 ビュー (過去 30 日間)
sachin narain
sachin narain 2018 年 6 月 5 日
回答済み: KSSV 2018 年 6 月 6 日
I have raw excel file imported in matlab.It is a 5x5 raw file.There are cells where there are 'NAN'in it .I have to find the indices of the 'NAN' rows in the raw file. Can anyone help me to solve this?
I have attached my raw file
  2 件のコメント
Jan
Jan 2018 年 6 月 5 日
What is a "raw excel file"? Where are these "NaN" 's displayed? Are they strings? Is this the array browser of Matlab?
sachin narain
sachin narain 2018 年 6 月 6 日
YEs .This is a browser of matlab.NAN's are but empty spaces in excel.In matlab it shows as NAN.

サインインしてコメントする。

回答 (1 件)

KSSV
KSSV 2018 年 6 月 6 日
YOu can get the NaN's position using: isnan
Rea dabout isnan for logical indexing. Also have a look on find.
A = [1 2 NaN 4 NaN] ;
idx = isnan(A) %logical indexing
pos = find(idx) % indices

カテゴリ

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

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by