Answered
Color gradient with linspace inside scatter.
a) the code in your question results in circles in different sizes but all the same colour, since the colour is the fourth argum...

10 years ago | 0

| accepted

Answered
I am doing a project on automatic license plate detection.I have executed this code but there are some errors.Please tell me what is the issue.
How is the error not clear enough for you? ERROR: Error using load Unable to read file code3.fig: No such file or directory...

10 years ago | 0

Answered
max and min value of matrix
I believe Ashvin is looking for <https://www.mathworks.com/help/images/ref/nlfilter.html |nlfilter|> rather than |blockproc|. I....

10 years ago | 1

Answered
nanmean statistics toolbox error
Well, you could always use the standard |mean| function which has supported the |'omitnan'| flag for several versions now and do...

10 years ago | 0

Answered
how to calculate bit depth of signal from its sample?
Hum, usually the compression ratio is the size of the data before compression divided by the size of the data after compression,...

10 years ago | 0

Answered
Order of instantiation & Events
I really don't understand the point of objects listening to their own events. Why not invoke the dataupdate method of the child ...

10 years ago | 2

| accepted

Answered
algorithm to select each elements (number)
Your question is very unclear. Most of your sentences are hard to understand, I'm afraid. From your example, it would appear ...

10 years ago | 0

Answered
Measure connected component's areas.
See <https://www.mathworks.com/help/images/ref/regionprops.html |regionprops|> which does exactly what you want.

10 years ago | 2

Answered
Finding row index an element in cell array
find(cellfun(@(subc) ismember(7, subc), c))

10 years ago | 0

| accepted

Answered
Automatically restart Matlab after Microsoft forces restart
Well, you can always add a matlab shortcut to the <https://www.google.com/search?q=startup+folder+windows windows startup folder...

10 years ago | 0

Answered
Extracting matrix from a matrix based with condition
B = A(A(:, 2)>2 & A(:, 2)<7, :) which shows that your example answer is missing a row.

10 years ago | 0

Answered
How to pause just one function, while others keep running?
Fundamentally, what you are asking cannot be done in matlab (unless maybe if you use the parallel processing toolbox). At the m ...

10 years ago | 1

Answered
Fetch data on specific condition from matlab
What do you mean by *fetch*? If you mean you only want to load the parts of variables in a mat file that satisfy a condition...

10 years ago | 0

Answered
How to split image based on sectors.
Here is one way of doing it: %width: width of mask images to generate, in pixels %height: height of mask images to gener...

10 years ago | 1

| accepted

Answered
Allowing old Matlab to use DOS command under UNC path
The bug report that you link applies to the Real Time Workshop *only* and it looks like the solution works around the issue by n...

10 years ago | 0

| accepted

Answered
Find max values of n previous values in a matrix without a loop.
Actually, the simplest solution is to use <https://www.mathworks.com/help/matlab/ref/movmax.html |movmax|> (since R2016a): ...

10 years ago | 1

Answered
Addpath with user defined string problem
As per Adam's comment, your format string is wrong. sprintf('C:\\Users\\%s\\xxxxx\\xxx\\xx', username) is the correct f...

10 years ago | 0

| accepted

Answered
how to index value falling particular interval
Use <https://www.mathworks.com/help/matlab/ref/discretize.html |discretize|>: v = [2 2 5 11 15 11 0 7 8 21 27 21 0 1 22 24...

10 years ago | 0

| accepted

Answered
How Can I avoid a loop for in a table?
An example of the data and an explanation of what you want to achieve would indeed have been useful. From your code, it would ap...

10 years ago | 0

| accepted

Answered
How to sum same size cell blocks?
sum(cat(3, inpt{:}), 3) is one way to do it. Basically, concatenate your matrices along an extra dimension and sum along tha...

10 years ago | 2

| accepted

Answered
How to convert a cell array of structures to array of structures
As long as the structures in the cells have all the same fields and that these structures in the cells are either scalar or arra...

10 years ago | 1

| accepted

Answered
compare and remove duplicates, not unique alone!
_"if the ratio between the values of the second columns > 50"_ _"could be more than 2 rows which have duplicates, so i have t...

10 years ago | 0

Answered
What is the "penalty" for using a try/catch?
The "penalty" has mostly been answered in the comments to the question. I'm posting this as an answer as I think you may have mi...

10 years ago | 0

| accepted

Answered
find a string from a cell array
Use a more useful date format, such as <https://www.mathworks.com/help/matlab/ref/datetime.html |datetime|> %your inputs: ...

10 years ago | 1

Answered
How can I remove rows and columns from two matrices?
A = [0 0 0 0 0; 1 0 0 0 0; 0 0 0 0 0; 0 0 1 0 0; 0 0 0 0 0]; B = [0 0 0 0 0; 1 0 0 0 0; 0 0 0 0 0; 0 0 0 0 0; 0 1 0 0 1]; ...

10 years ago | 0

| accepted

Answered
Subscript indices must either be real positive integers or logical error when saving Data on a vector.
You're using |k+(beta-alph)/deltagamma| as an index into |neighbour| with |beta = atan(ratio of integers)|. |beta| is rarely goi...

10 years ago | 0

Answered
stop the data comprising from 4 different loops in an array
You could modify your loops in order to create indices for your |Delta_a|: w = [0.01,0.1,0.3,0.8,3]; K = 4:9; T = 2:3...

10 years ago | 1

| accepted

Answered
Get the index of paired Values using allcomb
Instead of creating the cartesian product of the vectors, create the cartesian product of the indices of the vector: vector...

10 years ago | 1

| accepted

Answered
How do I create a loop for a .m file that has multiple functions in it?
Note: <https://www.mathworks.com/help/matlab/matlab_prog/local-functions.html local functions> (functions below the main functio...

10 years ago | 1

| accepted

Answered
Element extraction from Matrix based on column index from another matrix.
The fact that A is a cell array makes things a bit awkward, but otherwise it's trivial to do with |ismember| to find the matchin...

10 years ago | 1

| accepted

Load more