Is there a way to make a 4D contour plot?

20 Ansichten (letzte 30 Tage)
MathWorks Support Team
MathWorks Support Team am 21 Mai 2019
I am looking to visualize some 4 dimensional data. What would the best way to do this be?
I want to create a sort of contour plot but instead of lines, it would show a group of surfaces that represent different cross-sections of the 4D curve.

Akzeptierte Antwort

MathWorks Support Team
MathWorks Support Team am 13 Jun. 2019
You can create a 4D contour plot by using "isosurface" to plot a surface at 1 or more isovalues and setting the 'alpha' of each so that they are slightly transparent.
e.g.
[x,y,z,v] = flow;
levellist = linspace(-10,2,7);
for i = 1:length(levellist)
level = levellist(i);
p = patch(isosurface(x,y,z,v,level));
p.FaceVertexCData = level;
p.FaceColor = 'flat';
p.EdgeColor = 'none';
p.FaceAlpha = 0.3;
end
view(3)
Otherwise, MATLAB has a variety of other methods for visualizing 4D data. Take a look at this documentation link:

Weitere Antworten (0)

Kategorien

Mehr zu Contour Plots finden Sie in Help Center und File Exchange

Produkte


Version

R2017a

Community Treasure Hunt

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

Start Hunting!

Translated by