Linear fit for data from 3D matrix
9 ビュー (過去 30 日間)
古いコメントを表示
Hello community! I have a 3D matrix like this:
val(:,:,1) =
2.5620 2.0040 1.8380
2.2240 1.9160 1.9030
val(:,:,2) =
2.0330 1.9970 1.8180
2.4040 1.9330 1.9300
val(:,:,3) =
2.4260 2.1040 1.9050
1.9960 1.9630 1.9560
I need to make a linear fit for every group on z axis (here for example, 2.5620, 2.0330, 2.4260). For the fit in 2D plot (just to make it clear, I do not need the plot), the y axis is the same as the z axis of the 3D matrix (suppose simply 1,2 and 3)and x axis is based on the values of the element. After this, I have to get the values on the fit (by y=1,2 and 3) and use the values in 3D matrix minus the values from the fit. Could someone please help me on this? Thank you very much!
1 件のコメント
Star Strider
2015 年 9 月 10 日
I’m not entirely clear on what you’re asking. Please give an example of what you want to fit, specifying your independent and dependent variables.
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Interpolation についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!