Ouputting data from a function to an array
1 view (last 30 days)
Show older comments
Hi there,
I'm trying to output data from an sfit function to an array, so that I can use the surfnorm command. Basically I am receiving position data from Imaris, a 3-D visualization software and performing a surface fit. I am tasked with generating surface normals to the resulting surface (and I intend to use the surfnorm command). However, to create these normals, I need the xyz coordinates (in a particular range) from the resulting surface fit. How does one sequester the xyz coordinates for a surface fit (I'm using the thin plate spline interpolation)? Note--I already have turned the plotted function in the createfit function into a workspace variable called fitresult. However, whenever I open the variable in my command line, I receive the following answer.
Thin-plate spline interpolant:
fitresult(x,y) = thin-plate spline computed from p
where x is normalized by mean 3760 and std 185.2
and where y is normalized by mean 2812 and std 188.8
Coefficients:
p = coefficient structure
Thanks!
Cheers, Harsh
0 Comments
Answers (1)
dpb
on 16 Jun 2014
... the xyz coordinates (in a particular range) from the resulting surface fit
You had to have the coordinates to do the fitting; use those. If you need to select a subset within the total, use logical addressing. Perhaps giving snippet of the fitting code to show variables and more specifically where you're stuck???
3 Comments
See Also
Categories
Find more on Lighting, Transparency, and Shading in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!