Answered
Not enough input arguments.
Ahmed - the signature for this function is g = plot3k(L,c,marker,nlabels) Given the error message, it sounds like you are...

10 years ago | 0

Answered
Have a pop-up dialog which has license agreement?
A - I would create a separate GUI to handle the licensing information. When the user presses the Accept button, then you would ...

10 years ago | 0

Answered
How to Write entry indicated by each address for below matrix
Iatha - if you wish to initialize *A* as a 2x2 matrix with the above values, then just do A = [14 20 ; 26 20]; To access ...

10 years ago | 0

Answered
GUI Question: Save user preferences between everytime an application is launched?
A - when the GUI closes, you can save any data you want to a mat file. See <http://www.mathworks.com/help/matlab/ref/save.html ...

10 years ago | 0

Answered
Need help with a while loops problem
Hugh - delay adding your grade to the array until you know for sure whether it is valid or not. For example, you can replace yo...

10 years ago | 1

| accepted

Answered
change color of output graph
Anvinder - the problem is with the following two lines a(10:110,40:140)=0; a(120:200,120:200)=0; Remember, *a* is a 256...

10 years ago | 0

| accepted

Answered
Plot vectors must be same length
K - the error is because of this line fun2fit=@(params, time) params(1)*exp(-params(2)*t1)+params(3); Note how the second...

10 years ago | 0

| accepted

Answered
How to merge the waitbar into UIcontrol GUI
Statisticalbeginner - rather than using a slider to record your progress, consider using an axes object which you would then dra...

10 years ago | 0

| accepted

Answered
How to play video using data from structure.
Babu - are you trying to plot the *rho_video* data at each tilmestep? For example, could you do something like figure; fo...

10 years ago | 0

| accepted

Answered
Homework Help, Basic function
cwachts - the first line of your assignment is giving you the function name and signature. In the MATLAB editor, create a new f...

10 years ago | 1

Answered
Index out of bounds error
Also, *H1* and *H2* are initialized as H1 = length(t); H2 = length(t); You probably mean this to be H1 = zeros(N,1)...

10 years ago | 0

Answered
Figure plot only to file
nilsotto - to be clear, you just want to save the figure to file but not actually show the figure? Try setting its *Visible* pr...

10 years ago | 1

Answered
How to write an if statement that checks if array is real and positive?
Brian - since *A* is an array, you will want to use the <http://www.mathworks.com/help/matlab/ref/all.html all> function to ensu...

10 years ago | 0

| accepted

Answered
Simple for/cond statement
Salar - since your homework requires that you use a <http://www.mathworks.com/help/matlab/ref/for.html for> loop, then take a lo...

10 years ago | 0

Answered
Making a grayscale matrix
Perhaps I'm misunderstanding, but it seems that you are trying to just assign the same value to all elements within your matrix....

10 years ago | 0

Answered
Why my Game of Life explodes with rule 1133?
Vladimiro - all cells in the image go white not because all cells alive but rather because all cells are dead. I think that thi...

10 years ago | 0

| accepted

Answered
I am getting error "The length of X must match the number of rows of Y."
kaylani - at which line are you observing this error? Note that when I run your code, the only problem I observe is with ba...

10 years ago | 0

| accepted

Answered
Accessing empty array element through a loop
Harsha - I'm not clear on how your question title _accessing empty array element_ relates to your code. Where are you trying to...

10 years ago | 0

Answered
Firing Event if mouse enters graphic objects (figure, axes, button, etc.)
Hi Alex - you can use the *WindowButtonMotionFcn* callback to determine which child uicontrol object (within the figure) is unde...

10 years ago | 3

| accepted

Answered
Problems with if function:
Cedric - why are you subtracting the lower bound of the interval for the three highest salaries? Presumably the individual is t...

10 years ago | 0

Answered
How to move a figure horizontally?
Hannah - how have you created the gratings pattern? As an image (2D array) or using multiple graphics objects that you have crea...

10 years ago | 0

Answered
Any ideas why Euler method isn't running?
Kaylene - if I run your code, I notice that your *Y* array output from *euler* are all NaNs. Looking closely at this function ...

10 years ago | 0

Answered
GUI Push Button Undefined Variable
Sara - the *handles* structure does not reference those variables that you save to the workspace. It only includes the handles ...

10 years ago | 0

Answered
How to make a for loop for fft?
Sag - if *Final* is a cell array, then your *for* loop would look something like for k = 1:length(Final) YY = fft(Final...

10 years ago | 0

| accepted

Answered
Terminate Matlab function by closing GUI window
Mat - perhaps you could consider implementing a <http://www.mathworks.com/help/matlab/ref/handle.addlistener.html listener> to r...

10 years ago | 0

Answered
How to make gui to exe file
Buddhini - in order to create a standalone GUI, you will need the *MATLAB Compiler*. Information on this product can be found a...

10 years ago | 0

Answered
What to fix in this code to calculate harmonic mean with for loop?
Trent - you can consolidate the last two lines of code (of your *for* loop) to harmonic_mean = harmonic_mean + 1/z; which...

10 years ago | 0

| accepted

Answered
How can I replace my values in an iteration?
Maryam - perhaps the problem is with the first line of the *while* loop func_initialGuess = func(initialGuess); Every it...

10 years ago | 0

| accepted

Answered
How to put pictures in a GUI that opens from the main GUI!
Valarie - your line of code open('help01.fig'); just opens or displays the figure corresponding to the GUI but does not p...

10 years ago | 0

| accepted

Load more