Answered
printing full stop in next line
Replace: fprintf(fid2, '%s\n', c {:}) by str = sprintf('%s\n', c {:}); str = strrep(str, '.', [char(10), '.']); ...

8 years ago | 0

Answered
What is wrong with line 13?
Please consider Guillaume's advice. I dare to *guess*, that your "line 13" is f(x1) = f1; Here you could get the erro...

8 years ago | 0

Answered
Why don't my labels appear in a 3D plot?
The |surf| command clears the properties of the |axes| object, which removes the labels also. So insert them *after* the |hold o...

8 years ago | 0

| accepted

Answered
what is the name and meaning of this symbol?
This is the Greek uppercase psi. The meaning depends on the context. Of course you can call any function or variable "Psi". Actu...

8 years ago | 0

Answered
.fig file opens in non-editable way
set(gcf, 'Menubar', 'figure', 'Toolbar', 'figure')

8 years ago | 0

Answered
Connection Error launching a trial version
This is the public forum and the answers are given by other Matlab users voluntarily. You will get a more reliable answer if you...

8 years ago | 0

Answered
we have license of matlab but we want to take deployment license.
This is the public forum and answers are given by voluntary Matlab users. Therefore this is not the best place for this question...

8 years ago | 0

Answered
Is there a way to vectorize these loops for speed?
You compute expensive powers of |theta| repeatedly. Better do this once and store the values in a vector. What is the largest po...

8 years ago | 0

Answered
How can I perform statistics only on the numbers that come beforehand in a data set?
signal = rand(1, 1000); signal(300:1000) = signal(300:1000) + sind(300:1000); n = length(signal); cummean = c...

8 years ago | 1

Answered
Multiple cause exception handling
Does this help: R = getReport(e); ? Otherwise check the list in |e.cause| and display it in a loop. ... catc...

8 years ago | 0

| accepted

Answered
GUI help for collecting basic data
What do you mean by "output the pd matrix". Output to where? Using global variables or creating a variable in the base workspa...

8 years ago | 0

Answered
stars pattern using recursive function HELP
Do you know, what a recursive function is? You have to include a call to itself in the code. But this should not cause an infini...

8 years ago | 0

Answered
How do I find the value of x for a given value of y?
Do you mean the line: [Ymax, Xmax] = max(xA) ? But here you do get the maximum value of xA and its index already. So wha...

8 years ago | 0

Answered
How to mask an image that is subject to another image
Maybe you mean: Ic = Ib .* (Ia > k) Now all elements with Ia <= k are set to 0, while the others keep their values.

8 years ago | 0

Answered
How to choose one contour?
From the <https://www.mathworks.com/help/matlab/ref/contour.html documentation of contour>: To display a single contour line...

8 years ago | 0

Answered
Help With Scaling Image Without Using Toolbox
img = imread('DIP/pic.jpg'); x = round(linspace(1, size(img, 2), 256)); y = round(linspace(1, size(img, 1), 256));...

8 years ago | 0

Answered
How to set color bar to axes of tab 2 ?
Does this help: colorbar(handles.ax11, 'westoutside') ? It is safer to insert the parent of a graphics object, than to m...

8 years ago | 0

| accepted

Answered
How to use multiple grouping variables in boxplot? Why box plot grouping variable 'not same length' error?
I'm not sure what you are exactly asking for. But maybe this helps: data = round(10*rand(2,3)); data(:,2) = 2*d...

8 years ago | 0

Answered
Dynamically adding elements into an array every nth element based on user-defined inputs, while preserving array order
data = [ 1 2 3 4 5 6 ] ; n = 1; % Step width x = -1; % To insert len = numel(data); result = [dat...

8 years ago | 1

| accepted

Answered
mxCreateNumericArray error: cannot convert from 'const size_t *' to 'const int *'
According to the <https://www.mathworks.com/help/matlab/apiref/mxcreatenumericarray.html documentation>, mxCreateNumericArray re...

8 years ago | 3

| accepted

Answered
How do I make a figure full screen programmatically in MATLAB?
Under Windows you can use the API of the OS, see <https://www.mathworks.com/matlabcentral/fileexchange/31437-windowapi> : F...

8 years ago | 6

Answered
MATLAB Matrix Indexing - Image Processing
I'm not sure, but maybe you want this: dataV = reshape(data, 100, []); loc1 = (img == 1); result = dataV(loc1, :);...

8 years ago | 0

Answered
gui remembers old data
Without seeing the code? This would be pure magic. How could the reader know, what happens? We can only *guess*. And so do I: Yo...

8 years ago | 0

Answered
bisection method disadvantage?
Actually your should be able to find out by your own, why this value is replied. Simply use the debugger to step through your co...

8 years ago | 0

Answered
Deleting strings in a list
test = {'3.jpg', '4.jpg', '5.jpg', '6.jpg'}; test(strcmp(test, '4.jpg')) = []

8 years ago | 3

| accepted

Answered
Number of first days of the month equals to Mondays
This does not define a leap year: if mod(countYear, 4)==0 || (mod(countYear, 100)==0 && mod(countYear, 400)==0) You want...

8 years ago | 0

Answered
LZW Compression Via Gif Transformation
Writing GIF compresses the data with LZW, but adds a header also. If you really want this, |imread| can import the data again. ...

8 years ago | 1

| accepted

Answered
Evaluating a value of a function and add to the previous value using for loop.
The result is exactly, what is expected. Why do you assume it is wrong? The formula contains the term: abs(T-x) .^ -2 ...

8 years ago | 0

Answered
Storing a range as a variable
What's wrong with x(a:b) You really need to store it in one variable? Range.a = a; Range.b = b; x(Range.a : ...

8 years ago | 1

Answered
Can anyone help to resolve the issue with the error occured in matlab :
The message is clear already: fullfile('model', ['cluster_data_', num2str(opts.simThd), '.mat']); load(clusterName) ...

8 years ago | 0

Load more