Convert data from a 3d residual plot to a matrix?
이전 댓글 표시
Hello,
I have created a 3d residual plot from point cloud data. How can i now export these new residual x,y,z values as a 3 column matrix to do further work with?
As you can see from the image the residual plot at the moment is visually unclear due to the large amount of data points.
Any advice would be helpful. Thanks
Joe
%%Fit: 'Residual'.
[xData, yData, zData] = prepareSurfaceData( Dx3, Dy4, Dz2 );
% Set up fittype and options.
ft = fittype( 'poly55' );
opts = fitoptions( 'Method', 'LinearLeastSquares' );
opts.Normalize = 'on';
opts.Robust = 'Bisquare';
% Fit model to data.
[fitresult, gof] = fit( [xData, yData], zData, ft, opts);
% Plot residuals.
figure( 'Name', 'Residual Plot' );
plot( fitresult, [xData, yData], zData,'Style', 'Residual');
% Label axes
xlabel 'x (m)'
ylabel 'y (m)'
zlabel 'z (m)'
grid on
view( 0, 90 );
Dx3,Dy4,Dz2. These are the column vectors describing the intial raw data.
The code currently plots a fit to this data. Then creates a residual plot (plotting the points again above and below the fit).
So I am trying to extract these 'residual' points as a new set of data as 3 column vectors representing x,y and z or all together in a r column matrix.
채택된 답변
추가 답변 (1개)
madhan ravi
2018년 10월 19일
편집: madhan ravi
2018년 10월 19일
3_column_matrix = [ x(:) y(:) z(:) ]
댓글 수: 6
Joe Pashley
2018년 10월 19일
madhan ravi
2018년 10월 19일
Dx3, Dy4, Dz2 ???
Joe Pashley
2018년 10월 19일
madhan ravi
2018년 10월 19일
Can you upload the data’s of Dx3 and the other two so that we can test??
Joe Pashley
2018년 10월 19일
madhan ravi
2018년 10월 19일
We have to wait for someone who can proceed further , im finding it difficult to interpret
카테고리
도움말 센터 및 File Exchange에서 Smoothing에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!