Réponse apportée
Generate random number
Read the help of both functions and then take a look at NORMRND

plus de 15 ans il y a | 0

Réponse apportée
how to find maximum and second maximum number from vector.
One of the easier alternatives: m1 = mode(x) xcopy = x ; xcopy(x==m1) = [] m2 = mode(xcopy) Another options uses ...

plus de 15 ans il y a | 0

| A accepté

Réponse apportée
load multiple files with a condition on the file name
dfBASF = dir('*BASF.mat') ; for F = {dfBASF.name} curF = F{:} ; % current file disp(curF) movefile...

plus de 15 ans il y a | 0

| A accepté

Réponse apportée
Expanding Matrix
No need for loops, cell2mat or cellfun. Here is the simple approach using indexing: % data A = [1 2 3 ; 4 5 6] e...

plus de 15 ans il y a | 0

A soumis


RANDBLOCK
scramble matrices using blocks (v2.3, mar 2011)

plus de 15 ans il y a | 1 téléchargement |

4.0 / 5
Thumbnail

Réponse apportée
Inserting rows (location specified by ID)
Take a look at *insertrows* that ... well ... insert rows at locations specified by row indices. The problem than becomes ho...

plus de 15 ans il y a | 0

Réponse apportée
for loop
In the Matlab Editor, # select the text you want to tidy up # use the menu "Text" -> "Smart Indent" (or the shortcut, which...

plus de 15 ans il y a | 1

Réponse apportée
Append numbers to matrix
Why bother? Simply read in the values, append to the previous matrix and do a simple RESHAPE when needed.

plus de 15 ans il y a | 0

Réponse apportée
how to reshape an n x 1 matrix into a squre matrix using matlab?
This function will take any vector (or even a matrix) V and reshapesit into the smallest square matrix that can hold it. _Note t...

plus de 15 ans il y a | 1

| A accepté

Réponse apportée
Testing for identical numbers in matrix columns
Nothing shorter than: ~std(A)

plus de 15 ans il y a | 4

A soumis


MOVENAN (v1.0, mar 2011)
Move NaNs to the beginning or end of a column

plus de 15 ans il y a | 1 téléchargement |

0.0 / 5

Réponse apportée
Find index of cells containing my string
So, your original array was a cell array of cells with a single string. Use STRCMP and FIND to get the indices of the cells with...

plus de 15 ans il y a | 17

Réponse apportée
Search nx3 array row-wise for 2 equal elements
Here is another idea. First create an upper triangular 3D logical matrix (OLP) in which the elements OLP(k,j,i) (with j>k) repre...

plus de 15 ans il y a | 0

Réponse apportée
Adding arrays found using 'who' function
This is one of the (rare) cases EVAL comes in handy. evalStr = sprintf('%s+', Find_Target_Vars{:}) ; evalStr = evalStr(1...

plus de 15 ans il y a | 0

| A accepté

Réponse apportée
.coe file in matlab
Here is the link to the documentation: <http://www.mathworks.com/help/toolbox/filterdesign/ref/coewrite.html>

plus de 15 ans il y a | 0

| A accepté

Réponse apportée
Random values from histogram
Standing on the shoulder of a giant WR, the following run-length based code will create a random list of 10 values that are deri...

plus de 15 ans il y a | 2

| A accepté

Réponse apportée
Transfer the data from dos command prompt to MATLAB GUI text box
Check the help of the OS how to copy/paste from the command window.

plus de 15 ans il y a | 0

Réponse apportée
Randomly generate a matrix of zeros and ones with a non-uniform bias
The following gives you a matrix with exactly a certain number of 1's sizeR = [3 4] ; num1 = 8 ; R = zeros(sizeR)...

plus de 15 ans il y a | 3

Réponse apportée
Problem with Inputdlg function
You can set the resize option of inputdlg to on, as described in the help, although I doubt this will help you a lot. However,...

plus de 15 ans il y a | 0

| A accepté

Réponse apportée
Permute matrix elements across rows
I suggest to split the matrix into the elements you want to make combinations of using MAT2CELL X = [2 4 1 ; 5 3 6] ; % a dis...

plus de 15 ans il y a | 1

Réponse apportée
Simulating human vision system.
There is no answer for this question (if it is a question at all ...). I can only give you this advice: go to the one who asked ...

plus de 15 ans il y a | 0

Réponse apportée
Loop that creates arrays
If all the arrays are vectors (=1D arrays in matlab) you can store them in a matrix (=2D array). % Pre-allocate an matrix wit...

plus de 15 ans il y a | 3

| A accepté

Réponse apportée
Cutting rows and columns from a matrix
See ANY (or ALL). You need a two step approach: A = [1 0 1 0 ; 1 0 1 0 ; 0 0 0 0] B = A(any(A,2),:) ; % remove null rows ...

plus de 15 ans il y a | 1

| A accepté

Réponse apportée
How do I use randperm to produce a completely new sequence (no numbers in same place)?
I just resubmitted RANDPERMFULL to the FEX. It will be available in few days. To the OP, should the next permutation be diffe...

plus de 15 ans il y a | 1

A soumis


FLIPXYVIEW (v2.0, mar 2010)
flips (mirror rotates) the horizontal and vertical plot axes

plus de 16 ans il y a | 1 téléchargement |

5.0 / 5
Thumbnail

A soumis


CELL2FLOAT
converts cell array into scalar float array (v4.0, jan 2010)

plus de 16 ans il y a | 1 téléchargement |

4.66667 / 5

A soumis


UNIQUEWITHEQUALNANS
Set unique, treating NaNs as equal (v2.0, mar 2009)

environ 17 ans il y a | 1 téléchargement |

5.0 / 5

A soumis


BALLATSQ
Create a balanced latin square (v2.2, mar 2009)

plus de 17 ans il y a | 1 téléchargement |

5.0 / 5

A soumis


NDLINSPACE (v1.1, feb 2008)
Generalized LINSPACE: linearly spaced values between mutliple points

plus de 17 ans il y a | 1 téléchargement |

4.0 / 5

A soumis


FINDIND
find indices of matching elements between two matrices (v2.0, jan 09)

plus de 17 ans il y a | 2 téléchargements |

0.0 / 5

Charger plus