Answered
How to store value of for loop in a array
"some how it stops after 3 itrations at z = 0.03" That's actually not true. In your script, z contains 4 values and the loop h...

7 días ago | 1

| accepted

Answered
How to close mutiple uifigure using command
Just to add another approach, Set HandleVisibility to on when you create the UIFigures. That way their handles will be visibl...

8 días ago | 0

| accepted

Answered
How to check user input data using letters
The input() method of acquiring responses from a user is highly unconstrained and difficult to manage (see this example). What ...

8 días ago | 2

Answered
How do I use fill to create continuous error bars?
Having the imped_calc function matters because now we can see the size and shape of the outputs. freq is a 1x21 vector. Z_...

8 días ago | 1

| accepted

Answered
Plotting only the positive radius for a polar graph
"Is there a more efficient way to go about ths?" Yes❕ All of that in the loop can be done with this one line, r(r<0) = 0; ...

8 días ago | 2

| accepted

Answered
How can i convert the text to DNA sequence ?
Use regexprep to replace the matches in key(:,1) with the definitions in key(:,2). Since some DNA codes are special characters ...

8 días ago | 0

| accepted

Answered
Handle of UI component from which a context menu has been opened
Neither the cxMenuSelectionFcn nor the ContextMenuOpeningFcn functions indicate the object that evoked the context menu. Chec...

14 días ago | 1

| accepted

Answered
Custom Datatip with Line Information on Matrix Plot
Loop through the object handles and add the DataTipRows for each object. t = 0:.001:1; f = [10,20,30]; % information ...

15 días ago | 1

| accepted

Answered
3D Scatter with different Z axis vector length
I don't know how you're storing the variables but the demo below should get you started. It loops through values of R and you...

15 días ago | 0

| accepted

Answered
Plotting different colored line based on condition(s)
A line object can only have 1 color. To change the color of values above and below y=0 you have to break up your line into segm...

15 días ago | 0

Answered
Setting the figure size independent of the legend size
It sounds like you want to expland the axis size which would also require adjusting the figure size. Here's a demo. fig = f...

16 días ago | 1

| accepted

Answered
Diagonal displacement of matrix into another matrix
Fast & efficient vectorized method m is the input matrix size 2xN where N is divisible by 2. A is the output array containing...

16 días ago | 1

Answered
stacked 3d vertical bar
Combining the 'stacked' and 'detached' styles in a 3D bar plot is thoroughly explained here https://www.mathworks.com/matlabcen...

16 días ago | 0

Answered
Stacked vertical 3d plot sorting
bar3(__) styles and limitations Matlab's bar3(data) produces a n*m grid of 3D bars for n rows and m columns of the input matrix...

16 días ago | 0

| accepted

Answered
how can I store a set of segmented output images saved as individual mat files into a cell array
Set up your file names in an array such as filenames = {'201080.mat', '201081.mat', '201082.mat', '201083.mat'}; % full path i...

16 días ago | 0

Answered
Control chart function help
The second input to controlchart(x,group) is a grouping variable that defines which group each element of x belongs to. It must...

16 días ago | 0

Answered
Find z value out of x and y values from a countour in command window
A surf plot is not a contour plot. That was a little confusing. Thanks for clearing that up. Use the handle to your surface...

16 días ago | 0

Answered
Rescale multiple spheres on the same 3d plot
On the first iteration of the i-loop, n equals 6.9637.... This value is passed to sphere(n) and, as the error message indicates,...

16 días ago | 0

| accepted

Answered
How to overlap plots from different scripts?
Look up the documentation for copyobj. Not only is a new figure generated with the code you shared but a very important error...

16 días ago | 0

| accepted

Answered
Different results using mesh and surf
> The problem is the two graphs are different. The surf function seems to have gotten it correct, but the mesh function looks li...

16 días ago | 0

| accepted

Answered
How do I repeat a number based on a criteria?
Try out F = fillmissing(A,method) where method is set to "previous". To apply that to your table, it will look something like,...

17 días ago | 0

Answered
A function to set common properties for all open figures
h = findall(0, '-property', 'TickLabelInterpreter'); set(h, 'TickLabelInterpreter', 'Latex')

17 días ago | 0

| accepted

Answered
How can I add a drop-down menu for a certain column in a UItable in App Designer?
Refer to Matlabs documentation on the uitable's ColumnFormat property which demonstrates how to set up pop-up menus within a col...

17 días ago | 0

| accepted

Answered
How to create a Lambertian (diffuse) sphere
There are probably official definitions and methods for a Lambertian diffuse sphere but here's something that looks like it. ...

17 días ago | 1

| accepted

Answered
how can I fix Warning: Imaginary parts of complex X and/or Y arguments ignored.
Your data contain complex numbers. If this is unexpected, it indicates that there's a problem somewhere along your pipeline a...

18 días ago | 0

Answered
Code for Counting and Lookup
Here's a demo. v is the input vector of 1s and 0s (or Trues and Falses) r is the output vector of row numbers in v that star...

18 días ago | 1

Answered
How to display plot and rectangle at the same time?
" I have tried 'hold on' , but that didn't work" My guess is that hold on was applied to the wrong axes. This can happen when ...

18 días ago | 0

| accepted

Answered
How can I use ginput in app designer?
ginput is now supported in AppDesigner starting in r2020b We still don't have an option to specify the target figure handle in ...

18 días ago | 1

Answered
How we can plot Indian flag ploting
Download an image of the flag. use imread and imshow to read/plot the flag. Here's an example https://www.mathworks.com/...

18 días ago | 0

Answered
How to unpack a table with a column of structs while preserving other columns?
Tnew is the input table (attached). gtTbl = cellfun(@struct2table, Tnew.groundtruth2DBB, 'Unif', false); T = [repelem(Tnew(:...

19 días ago | 0

| accepted

Load more