Linear Regression with NaN Elements
13 ビュー (過去 30 日間)
古いコメントを表示
Hi everbody,
I have a data set which is named as AA.
AA=[0.02 NaN NaN NaN 0.03 0.035 0.045 NaN NaN 0.05 0.059]
I should create a linear regression on NaN elements. (regression must be created from 0.02 to 0.03 and from 0.045 to 0.05 )
How can i done it?
Thanks.
2 件のコメント
回答 (1 件)
Birdman
2018 年 1 月 9 日
Something like this?(replacing NaN values with the mean of array without including NaNs)
AA(isnan(AA))=mean(AA(~isnan(AA)))
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Linear Regression についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!