Answered
Two x-axis for the same contourf plot
Matab does not currently offer a second x axis. You can create two duplicate axes and place the x-ticks of the bottom axis on ...

6 years ago | 0

| accepted

Answered
String scalar or character vector must have valid interpreter syntax
You probably want something like title(sprintf('%.2f + %.2f', Rs(1), Ry(1))) See sprintf for more info. Update Set interpre...

6 years ago | 0

| accepted

Answered
calculation time in for loop
If the computations done within the loops are nearly uniform in their complexity, then it's expected that the speed of each loop...

6 years ago | 0

| accepted

Answered
Error using fprintf Invalid file identifier. Use fopen to generate a valid file indetifier
My guess is that Total_Time_t2_64Mb is equal to NaN which would result in s2 = "TOTAL FRAMES SENT = " + NaN +...

6 years ago | 0

| accepted

Answered
Labels to a stacked bar
Here's a demo. % Create stacked bar plot x = randi(3,20,5); h = bar(x,'stacked'); % Get the (x,y) coordinates for the t...

6 years ago | 0

| accepted

Answered
Unnecessary rounding when reading an xlsx
Thanks for providing the raw data. I'm not seeing what you're seeing. My data exporation steps are below. % Read-in the da...

6 years ago | 0

| accepted

Answered
Finding handles to ROI objects such as drawline
h = findobj(axhl, 'type', 'images.roi.line'); The object created by drawline is different from regular line objects. But the...

6 years ago | 0

| accepted

Answered
Index in position 1 exceeds array bounds (must not exceed 46)
The value of n iterates from 1 to 617. The size of D is 46x16. When n=47, you get the error because D(47,:) doesn't exist. ...

6 years ago | 0

Answered
Error in callback function execution in App Designer when called programmatically
As of r2020a, the typical ToolBar is not (yet?) supported for UIFigures (eg, apps) but the property exists which usually means t...

6 years ago | 0

| accepted

Answered
Shift Map in App Designer
Since the worldmap function does not currently support setting parent axes, you'll have to create the plot in an external figure...

6 years ago | 0

| accepted

Answered
App Designer: Subplots in uiplane
Since this isn't your code, I don't have to worry about sounding insulting when I say that this code is a mess! :) I wouldn't ...

6 years ago | 1

| accepted

Answered
Custom Colors for Stacked Bar Chart
Set the FaceColor property to Flat and then define the colormap which specifies the color for each segment. Here are two demos...

6 years ago | 0

Answered
How to close an uialert programmatically
The uialert window cannot be programmatically closed, at least not in r2020a. You can, however, make the uialert non-modal whic...

6 years ago | 0

| accepted

Answered
extract data from structure into table with multiple columns instead of one column
Change T2 = [T2; ICA_selected] % ^ vertical concatenation to T2 = [T2, ICA_selected]; % ^ horizontal concatena...

6 years ago | 0

| accepted

Answered
how can I increase the patch animation speed?
In addition to Star Strider's advice to use getframe, check out drawnow limitrate which will limit the number of times drawnow i...

6 years ago | 0

Answered
Variable X-Tick Labeling
The cleanest solution IMO is to convert your datetime values to the fiscal year values and use the fiscal year values to plot yo...

6 years ago | 0

| accepted

Answered
Multiple X axis in different scale, but one y axis
Matlab does not support mutliple x axes other than the axes at the upper and lower borders of the plot. One way to include mu...

6 years ago | 2

| accepted

Answered
Change the color of each group in boxplotGroup
"Is it possible to have both a in each group green; and have both b in each group yellow?" Yes. Use the "colors" propery but i...

6 years ago | 1

| accepted

Answered
Making a contour plot from x and y data
The bivariate density can be computed using histcounts2. You'll need to specify either the number of bins or the bin edges for ...

6 years ago | 0

| accepted

Answered
Checking the dates and times
Why not use a UI such as https://www.mathworks.com/help/finance/uicalendar-graphical-user-interface.html https://www.mathwork...

6 years ago | 0

| accepted

Answered
Overlay plot of UIAxes
You can plot the line using xline() and then merely update it's Value property to move it. The line's handle must be stored as a...

6 years ago | 1

| accepted

Answered
Text beside the pointer in ginput
No can do. The ginput function suspends all interactive properties of a figure window so even if a WindowsButtonMotionFcn func...

6 years ago | 1

| accepted

Answered
Generation of random numbers in batches
The seeds below are chosen arbitrarily. rng(1) a = rand(1,100); rng(2) a3 = rand(1,100); a2 = [a,a3] You don't even ...

6 years ago | 0

Answered
Matlab still busy a long time after last line of script is executed
This is a known issue with Live Editor. See this potential solution. https://www.mathworks.com/matlabcentral/answers/535869...

6 years ago | 0

| accepted

Answered
Plotting graph in the appdesigner from the object handle - h
The show() function within the OpenIf classdef creates its own indpendent figure and axes. The only way to show the plot within...

6 years ago | 0

| accepted

Answered
Time axis as x axis
Assuming you've got a vector of time stamps the same size as the signal vector, convert the time stamps to datetime values and t...

6 years ago | 0

Answered
How long i can try out the matlab online course?
https://www.mathworks.com/learn/tutorials/matlab-onramp.html The self-paced courses are available for as long as you have a val...

6 years ago | 0

| accepted

Answered
How to random a chart?
Use random permutations. Apply this example to your data. words = ["A" "B" "C" "D" "E" "F" "G" "H"]; randIndex = randperm(n...

6 years ago | 0

Answered
How to plot a graph using if function
I don't see any plotting commands so I don't know what kind of plot you're trying to create. The problem can likely be solved ...

6 years ago | 0

Answered
app designer tab control question
app.UIAxes.Toolbar.Visible = 'off'; %|__________| replace with your axis handle. More info on the axis toolbar: https://w...

6 years ago | 1

| accepted

Load more