How to replace missing values in a cell array?
x = {missing(), 1, 2, 3, missing(), missing(), 5}; mask = cellfun(@ismissing, x); x(mask) = {[]}; % or whatever value yo...

7 meses ago | 1

| accepted

Interpolating random values to smoothen a curve
you can implement the stavisky golay filter basically the idea is to iterate through the data and on each point perform a polyn...

7 meses ago | 1

| accepted

Scatter Plot with string in x-axis and integer on y-axis
Maybe bar chart would be better for you, but if you must use scatter plot scatter(1:5,percentage); set(gca, 'XTick', 1:5...

7 meses ago | 0

how to add lable into rows
You need to use an inner join t3 = join(otherTable,goods,'key','keyColumnName') Or if the key column name is different i...

7 meses ago | 0

| accepted

Putting the result from eval into a cell array
please please please don't use eval to access varriable names eval is not built for that, however, for some reason the first th...

7 meses ago | 0

how to replace the elements row by rows instead of column by column in matrix
find(A==3,1,'first') find(A==3,1,'last') These lines find linear indices not [row, col] subsets. Linear indices go alon...

7 meses ago | 0

| accepted

MATLAB HELP ME PLS
The trapezoidal integration method is a numeric calculation which approximates the area trapped between the curve and the x axis...

7 meses ago | 0

How to access a function under a given path?
A possible solution would be to make every git branch a package. You will have to make all subfolders packages as well, but that...

7 meses ago | 0

| accepted

how to convert the fraction part into intger?
What about K = round(mod((abs (L)-floor (abs (L))) *10e8 , 256)) Or K = floor(mod((abs (L)-floor (abs (L))) *10e8 ...

7 meses ago | 0

For loop with subs
You are setting a 2x3 matrix into l2, which duplicates mat for all possible substitutions 2x3 times 2x3 = 4x9

7 meses ago | 0

Submitted

zoomginput
Zoom in/out of plot with your mouse wheel while using ginput

7 meses ago | 1 download |

Question

How to change property behavior for a mocked object
I'm trying to use the mocking framework for unit tests I'm trying to make the property of a mock object return another mock obj...

7 meses ago | 1 answer | 0

### 1

How to know dimensions to give in trapz function
let's say you have a column vector x and you calculate y according to y = ax^2 now if a is a vector, you will get a matrix y: ...

7 meses ago | 0

Adding dropdown option from GUI in App Designer
I would put the options in a text file. Then load it during startup

7 meses ago | 0

| accepted

How to plot plot from differnet location in a single figure?
If i understand your question corectly, and you have several .mat files each one with a varriable T and a varriable output, you...

8 meses ago | 0

Rearrange any matrix Randomly with a specific sequence
A=1:20; blockSize = 5; nOutputBlocks = 2; a=reshape(A,blockSize,[]); i=sort(reshape(randperm(size(a,2)),[],nOutput...

8 meses ago | 0

How to transfer data between apps using app designer
The simplest solution would be to couple the two apps. When you open app B send the object of app A to it. Then when app B upd...

8 meses ago | 0

Moving NaN elements from the last columns to the first column, iteratively
The simplest way would be to loop through the rows: i = isnan(A); for j = 1:size(A,1) A(j,:) = [A(j,i(j,:)) A(j,~i...

8 meses ago | 1

| accepted

Replace the elements of a matrix
B = reshape(A',numel(A),1)

8 meses ago | 0

Save char array from for loop into a matrix
Unless you can guarantee that all file names have the exact same length, you need to use something other than a char matrix. E...

9 meses ago | 0

| accepted

What frustrates you about MATLAB?
The implementation of properties. They are class fields, and they are the accessor methods to these fields, (get/set). This dual...

9 meses ago | 0

Could anyone help me how to randomly display the values in the selected places
if you meant to fetch values from a random index using above mentioned linear indices: a = magic(5); a = a(1:3,:); validInd...

9 meses ago | 0

How to convert a cell array containing various inline functions to a unique inline function?
You can generate a function handle which will execute all the handles in a cell array using closures: a = magic(3); myFunction...

9 meses ago | 0

Could anyone help me to solve the following issue
a = [1 2 3 4 5; 6 7 8 9 10] a_rand = a(randperm(length(a))) a_rand = [a_rand; a(~ismember(a(:),a_rand(:)))']

9 meses ago | 0

can matlab find ilaplace
Try that: syms s; F = exp(-y*sqrt(s+a))/s; F1 = ilaplace(F); pretty(F1); I don't know what a and y are in your ...

10 meses ago | 0

Select all Rows that Contain A Certain Number and Any NaN's That follow Them
I think in this case a simple loop will be better than a fancy vectorised solution. valid = false(size(A, 1),1); vali...

10 meses ago | 0

| accepted

How to clear persistent variables?
You can clear the name of the .m file in which that function is declared it works for .m file functions, local functions, neste...

10 meses ago | 0

Extract Previous Cell Value
The problem is you're indexing at index 0 which is invalid. % some specific handling of % the first cell should be % ...

10 meses ago | 0

regexrep for the neophyte
match = regexp(recipients,'(?<name>[a-zA-Z]+(?:\s*[a-zA-Z]+)*)\s?\\$?(?<sum>\d+(?:[\.,]\d+)*)[^\w,;]*(?<time>[a-zA-Z]+\d+)?','n...

10 meses ago | 1

| accepted

Question

multiple populations in a single pole
I have histograms that most likely represent multiple populations. If they distribute normally I know I can use curve fitting...

10 meses ago | 0 answers | 0