How many template of 3D graph exist in Matlab ?

6 visualizzazioni (ultimi 30 giorni)
As we know there is a lot template for sketch the 3D graph in matlab like real imaginary absolute and contour and density and so on how we can gether them in one package any one have it?

Risposte (3)

dpb
dpb il 5 Ott 2024
I don't know what is meant, specifically, with the reference to the data classes; particularly imaginary as MATLAB grpahics don't display imaginary values at all, but probably the best compendium of the available graphs is in the <base documentation link to 2D and 3D graphs>. The others available in extended toolboxes are not gathered in any one place that I'm aware of although a number are overloaded functions that will operate on various specialty axes (like mapping) or handle specific subject areas.
It is difficult as the universe keeps expanding to have any idea of all that are available, indeed, agreed...
  10 Commenti
John D'Errico
John D'Errico il 6 Ott 2024
Modificato: John D'Errico il 6 Ott 2024
NO. I am not trying to destroy your morale. Instead I am telling you there are no templates of the kind you are searching for. At best, there is one (or more) line in the help of each function.
help plot3
plot3 - 3-D line plot This MATLAB function plots coordinates in 3-D space. Vector and Matrix Data plot3(X,Y,Z) plot3(X,Y,Z,LineSpec) plot3(X1,Y1,Z1,...,Xn,Yn,Zn) plot3(X1,Y1,Z1,LineSpec1,...,Xn,Yn,Zn,LineSpecn) Table Data plot3(tbl,xvar,yvar,zvar) Additional Options plot3(ax,___) plot3(___,Name,Value) p = plot3(___) Input Arguments X - x-coordinates scalar | vector | matrix Y - y-coordinates scalar | vector | matrix Z - z-coordinates scalar | vector | matrix LineSpec - Line style, marker, and color string scalar | character vector tbl - Source table table | timetable xvar - Table variables containing x-coordinates character vector | string array | cell array | pattern | numeric scalar or vector | logical vector | vartype() yvar - Table variables containing y-coordinates character vector | string array | cell array | pattern | numeric scalar or vector | logical vector | vartype() zvar - Table variables containing z-coordinates character vector | string array | cell array | pattern | numeric scalar or vector | logical vector | vartype() ax - Target axes Axes object Name-Value Arguments Color - Color [0 0.4470 0.7410] (default) | RGB triplet | hexadecimal color code | 'r' | 'g' | 'b' | ... LineWidth - Line width 0.5 (default) | positive value MarkerSize - Marker size 6 (default) | positive value MarkerEdgeColor - Marker outline color "auto" (default) | RGB triplet | hexadecimal color code | "r" | "g" | "b" | ... MarkerFaceColor - Marker fill color "none" (default) | "auto" | RGB triplet | hexadecimal color code | "r" | "g" | "b" | ... Examples openExample('graphics/Plot3DHelixExample') openExample('graphics/Plot3MultipleLinesExample') openExample('graphics/Plot3MultipleLinesMatricesExample') openExample('graphics/Plot3WithTitleAndAxisLabelsExample') openExample('graphics/Plot3MarkersOnlyExample') openExample('graphics/Plot3CustomColorAndMarkerExample') openExample('graphics/Plot3SpecifyLineStyleExample') openExample('graphics/Plot3ModifyLineAfterPlottingExample') openExample('graphics/Plot3TableDataExample') openExample('graphics/Plot3TableMutliVariablesExample') openExample('graphics/Plot3SpecifyAxes19bExample') openExample('graphics/Plot3DurationDataExample') openExample('graphics/Plot3LineWithOneMarkerExample') See also axis, scatter3, bar3, tiledlayout, nexttile, grid, Line Properties Introduced in MATLAB before R2006a Documentation for plot3 doc plot3
For example, in the help for plot3, you will find some basic calling sequences, where if you follow them, they will yield a valid result.
plot3(X,Y,Z)
plot3(X,Y,Z,LineSpec)
plot3(X1,Y1,Z1,...,Xn,Yn,Zn)
plot3(X1,Y1,Z1,LineSpec1,...,Xn,Yn,Zn,LineSpecn)
It is not that we do not wish to share a template with you. There are no templates that you can just click on and get the result you desire to see. MATLAB is not Excel. As I said, if you need to use MATLAB, then you need to read the help. In there, you will find examples of how to call the codes. And that is as close as we can come.
dpb
dpb il 6 Ott 2024
@salim saeed, <TECPLOT, an alternative plotting package> does have many other prepackaged forms; although I doubt even it has precisely the above. It, however, is not inexpensive, either.

Accedi per commentare.


dpb
dpb il 6 Ott 2024
Modificato: dpb il 6 Ott 2024
And, to hopefully get your morale/optimism back up; it may not be nearly as much effort to create something like or close to the examples as you may think...
Z = peaks; % draw a surface w/ contours
sc = surfc(Z);
hold on % let add more w/o erasing
hAx=axes('Position',[0.7 0.7 0.25 0.20]); % another axis overlaying this one
hL=plot(hAx,Z(:,fix(width(Z)/2)),'linewidth',2); % draw a line into it of the data
xlim([0 50]), xticks([0:10:50]) % neaten it up a little...
ylabel(hAx,'Magnitude')
The rest will be created by using a subplot or tiledlayout arranged to place a matrix of axes in a given figure, it may be necessary to use the venerable subplot() here because I don't think you can put the second axis on top of another one in the tiledlayout--I think I recall having tried that and discovering it doesn't allow it.
The other plot could be as simple as
figure
hP=pcolor(Z);
hP.EdgeColor='none';
and then enhancements...
Don't let the need to write a few MATLAB commands overwhelm you...start in and try something...
  3 Commenti
salim saeed
salim saeed il 7 Ott 2024
@dpb thank you you did a great job thank for hardd work and your information.
Bruno Luong
Bruno Luong il 7 Ott 2024
@dpb possibly using GUIDE or AppDesigner to place the axes, a step forward to a so called "template"

Accedi per commentare.


Walter Roberson
Walter Roberson il 7 Ott 2024
Modificato: Walter Roberson il 7 Ott 2024
How many template of 3D graph exist in Matlab ?
No templates of 3D graphs exist in MATLAB.
No templates of 2D graphs exist in MATLAB either.

Categorie

Scopri di più su Graphics Object Programming in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by