Answered
Set condition when index exceeds array bounds
I would recommend that you use KSSV's answer to modify your loop so it indeed stops at numel(x)-1. The alternative is to fix yo...

7 years ago | 0

Answered
Undefined variable "vision" or class "vision.TextInserter".
Install the computer vision toolbox. If you don't have a license for it, then you cannot use the code you're trying to use.

7 years ago | 0

Answered
How do I convert relative Gregorian days since 1935-01-01 to calendar datetime (days with hours,mins,sec)?
Probably, dt = datetime(yourtimestamps*24*3600, 'ConvertFrom', 'epochtime', 'Epoch', '1935-01-01')

7 years ago | 0

| accepted

Answered
Finding rows of matrix A that do not overlap with any rows in Matrix B (without using for or while loop)
A = [ 0 50; 200 250; 300 350; 400 450]; B = [50 200; 200 300; 300 400]; isoverlap = any(A(:, 1)' >= B(:, 1) & A(:, 2)' <= B(...

7 years ago | 1

Answered
Remove same element from vector
What you have completely failed to mention in your question and left for us to guess is that your E matrix represents the edges ...

7 years ago | 0

Answered
Renaming categories with accents
str = {'Á', 'É', 'Í', 'Ó', 'Ú','Ã','Ç','Â','Ê','Ô'}; strreplace = {'A', 'E', 'I', 'O', 'U','A','C','A','E','O'}; t = categoric...

7 years ago | 0

| accepted

Answered
Error in the Code shown below:
Isn't the error obvious? You defin handles.text_ch as an empty array and then try to access its elements 1 to 32. Since it's emp...

7 years ago | 0

Answered
How do i change the length of a vector in a for loop without it causing an index out of bounds error?
You can't delete elements of an array while you're iterating over it unless you work in reverse and are extremely careful. Howe...

7 years ago | 1

| accepted

Answered
how to create random number of 64 bit length like this for example'B8FF5AF858E2746937204FB9C8B102D7ECC50A60B4BA3944AC7A9F3C2DD4C4EF'
That number is not 64-bit long. It is 64 hexadecimal characters long, which would be 64*8 = 512 bits! To create a 64-character ...

7 years ago | 0

| accepted

Answered
How to remove the unwanted characters and special symbols using regular expression?
"everything before '#' and every thing after'.' need to be cleared or truncated" then it's very easy: regexp(yourinput, '(?<=#...

7 years ago | 2

| accepted

Answered
Is there a way to access a specific element of an output array without assigning the output to a variable first?
Yes, [ClassA.CBO.infArray](inds) attemps to index the return value of a function, which matlab does not allow. You could do the ...

7 years ago | 1

| accepted

Answered
To concatenate two images
"but its not working" is a useless statement without telling us why it's not working (you get an error, if so, what error? you ...

7 years ago | 3

Answered
How can I fix my code so that my information displays to the screen in a user friendly format?
How about: disp(read); in your while loop? Otherwise, use something more sophisticated such as fprintf. I don't understand wh...

7 years ago | 0

Answered
How can I replicate {:} behaviour when overloading subsref in my class?
I think it was a bad design decision of mathworks to use the same function for all types of indexing forcing you to handle even...

7 years ago | 0

Answered
How to input text file into matlab as an array
Probably, the easiest: opts = detectImportOptions('15048.txt'); %let matlab figure out most of the file format opts.ImportErr...

7 years ago | 1

Answered
Is it possible to end this script once a negative number comes from the matrix? The final answer M has to be positive
I thought that I did that using the while loop function. Since your whole simulation is inside the while loop, the while test i...

7 years ago | 0

| accepted

Answered
why does audiowrite cast int16 different than the cast function?
If you follow the code of audiowrite, the floating point array is never converted and is passed as is to asyncioimpl.OutputStrea...

7 years ago | 1

| accepted

Answered
Help browser and academic license
Open your preferences in matlab. Under Help, change the documentation location from web to installed locally. Of course, if the ...

7 years ago | 1

| accepted

Answered
How to access a string array and use the contents as titles within array2table
I would create your storehere array, this way: storehere = compose("mean of bootstrapped coherence between %s and %s", nchoosek...

7 years ago | 0

| accepted

Answered
I have a .txt file which is not in a 'MATLAB' friendly format and I am trying to manipulate the data so that I can then delimit it and plot it later
I don't know what format you want ultimately, nor what can change in the format of the file. This is how I'd start: filecontent...

7 years ago | 0

Answered
Index exceeds matrix dimensions.
"When I run those lines I get the following error but I don't understand why" That would be because find(vals==0) returns one (...

7 years ago | 0

Answered
Include "a" character in a wordcloud
Bear in mind that this is with base matlab. The text analytics toolbox, which I don't have, may have some better ways of doing w...

7 years ago | 0

| accepted

Answered
How can I compute all the possible differences of the vectors in a matrix?
result = A - permute(A, [3 2 1]) would return a size(A, 1) x size(A, 2) x size(A, 1) array where result(i, :, j) is the differe...

7 years ago | 0

| accepted

Answered
To group the matrix based on the number on their column (of non-zeros)
[row, column] = find(Matr); groups = splitapply(@(rows, columns) {[rows, columns]}, row, column, column)

7 years ago | 1

| accepted

Answered
fopen / fprintf: Write to same file from independent processes
Your problem is not restricted to matlab. You would have the same problem in any other programming language. You basically have...

7 years ago | 0

Answered
Percentage of a value in a table rows matlab
A = [3 5 4 6 2 7 5 11 12 2; 1 4 3 6 7 5 3 7 12 10; 6 8 7 9 4 12 12 6 7 9] sum(A == 12, 2) / size(A, 2) * 100

7 years ago | 0

| accepted

Answered
How to remove table data based on comparison between different columns in another table in MATLAB?
It's fairly simple to do. Annoyingly implicit expansion and bsxfun don't work with datetime so you have to use repmat to do the ...

7 years ago | 0

| accepted

Answered
How can i re-write this bilinear search to help me understand?
I don't think whoever wrote that code understood what they were writing either. In particular, you have to wonder what was going...

7 years ago | 0

Answered
How to create a for loop to calc average of datas in a STRUCTURE?
First, note that in matlab, a structure is particular data type. Here you're using structure with its non-matlab meaning. It can...

7 years ago | 1

| accepted

Load more