Respondida
Error using horzcat Dimensions of matrices being concatenated are not consistent.
Isn't the error message clear? Obviously, a0 has more than one row, hence you can't concatenate it with a one row matrix. As we...

más de 7 años hace | 0

Respondida
Vectorise or make this code run faster
This is really basic matlab Z = I(:, :, 1) - I(:, :, 2) - I(:, :, 3);

más de 7 años hace | 0

Respondida
Hide class property, but retain autocomplete?
Hidden means hidden, from display and autocompletion. There's no workaround. However, what you could do is customise the displa...

más de 7 años hace | 3

| aceptada

Respondida
Elementary question, for loop implementation
As we've just said in your previous question, do not create numbered arrays. It's always the wrong approach, as you can see now,...

más de 7 años hace | 0

Respondida
Creating arrayfun with two variables
You seem to be expecting implicit expansion out of arrayfun (the way bsxfun works). arrayfun doesn't do that (and bsxfun can't c...

más de 7 años hace | 0

| aceptada

Respondida
please, how do we give each region a color after the segmentation ?
label2rgb is one way to do it.

más de 7 años hace | 0

Respondida
i want to change [3,2,4](1x3 matrix) to 324(1x1 matrix) any help?
polyval(yourvector, 10) would also work But what if your vector is [30, 20, 40]?

más de 7 años hace | 1

| aceptada

Respondida
Using the PNG algorithm to save a .mat file
The compression method that PNG uses is the well established deflate algorithm. This is the same algorithm that gzip uses and is...

más de 7 años hace | 0

Respondida
find the longest monotonically increasing subsequence of a sequence of n numbers?
Your question is confusing.You talk of finding "the longest monotonically increasing subsequence of a sequence of n numbers", th...

más de 7 años hace | 0

Respondida
How to index 8 surrounding cells in a 6x6 2D matrix?
Oh, so you're implementing a variation of Conway's game of life except that your cellular automaton has three states instead of ...

más de 7 años hace | 1

Respondida
Divide table takes a lot of calculation time
I doubt you're using any feature of a table with a table that large so why not store your data in a matrix instead. Matrix opera...

más de 7 años hace | 1

| aceptada

Respondida
How can I remove entire rows from a table based on NaN values in a specific column (cell data type) in a table?
Note that it's not usually a good idea to mix textual and numeric content in the same column of a table. Additionally, since you...

más de 7 años hace | 1

Respondida
Read text file and separate text from numerical values
Depending on what exactly you want to import, this could work: opts = fixedWidthImportOptions('NumVariables', 8, ... ...

más de 7 años hace | 0

| aceptada

Respondida
Scam Matlab Help Chat
I've just had it confirmed by Mathworks that it is legit

más de 7 años hace | 0

| aceptada

Respondida
How can I convert my .txt files to .xls using xlswrite
An example of a text file would be very useful. What you want to do would probably be very easy to do using the modern import an...

más de 7 años hace | 0

Respondida
How can I concatenate a 3-d matrix to 2-d?
Two methods, I'll let you test which one is faster, probably the permute one: B = reshape(permute(A, [1 3 2]), [], size(A, 2)) ...

más de 7 años hace | 1

| aceptada

Respondida
Setting object properties without returning the object using obj = obj.myfun(obj,argin)
What you want is a handle class. See Comparison of Handle and Value Classes for more details. Note that if you're not proficien...

más de 7 años hace | 0

| aceptada

Respondida
Find empty cells in excel
Have you checked what the content of raw actually is for cells that are empty in excel? In my version of matlab (2018b) with my ...

más de 7 años hace | 0

Respondida
How to cipher an input file?
dlmread is not for reading text files.The easiest way to import a text file is with fileread. plik = fileread(fid); %note that ...

más de 7 años hace | 1

| aceptada

Respondida
How to recursively go through all directories and sub directories and process files?
Since R2016b, dir can recurse through subdirectories using **. So it's as simple as: rootdir = 'C:\somewhere\somedirectory'; f...

más de 7 años hace | 18

| aceptada

Respondida
gcf repeatedly returns gui and not newly created figures
How do I ensure that my print command prints the figure that is on top at the time? Simple, don't rely on the current figure si...

más de 7 años hace | 2

| aceptada

Respondida
How to search for the same value found in one matrix in another matrix
is there a way i could change it so I only recieve the first value? You can tell find to return the first value: [row, col] = ...

más de 7 años hace | 0

Respondida
Creating combinations of 3 vectors
Akira's answer is how I'd do it. Just for the record here is another method indices = dec2base(0:size(A, 1)^size(A, 2)-1, size...

más de 7 años hace | 1

Respondida
hyper-spectral image displays in not true color it shows in blue
I'm sorry to say I'm struggling to understand what you're asking so my answer may be completely off the mark. I think you may b...

más de 7 años hace | 1

| aceptada

Respondida
Using ismember to get the corresponding elements
I think I understand what you want, if so, you're using ismember the 'wrong way round': function real_time = time_from_videos_t...

más de 7 años hace | 0

Respondida
How to pass a string (LPSTR) command to my C++ function?
I think you need to go back through the documentation of the function that you're using. I would never expect to have to pass a ...

más de 7 años hace | 1

Respondida
I keep getting 'Index exceeds array bounds.' my code doesn't like r(i)
"my code doesn't like r(i)" There's no liking involved. Your code does exactly what you tell it to. If you tell it to do someth...

más de 7 años hace | 0

Respondida
Rightmost Digit Counter Script - Index exceeds array bounds
The best way for you to understand the problems with your code (unfortunately there are many), is to debug it yourself. Step thr...

más de 7 años hace | 0

Respondida
Converting hexadecimal to decimal in base 10 using a loop (not function hex2dec)
For reference, here is how I would implement the conversion efficiently in matlab (without using hex2dec): hex = upper(input('E...

más de 7 años hace | 0

Respondida
Condition on the last last frame of a video
Well, you need to ask the filesystem for the list of files, extract the file numbers from that list then select the greatest one...

más de 7 años hace | 0

| aceptada

Cargar más