A répondu

Map triplets to a matrix

You can try the ismembertol function: [XX,YY] = meshgrid(0:0.1:1,0:0.1:1); Points = [XX(:),YY(:)]; PointsToMatch = [0,0; ...

Map triplets to a matrix

You can try the ismembertol function: [XX,YY] = meshgrid(0:0.1:1,0:0.1:1); Points = [XX(:),YY(:)]; PointsToMatch = [0,0; ...

plus de 2 ans il y a | 0

A répondu

Finding the mean of a histogram

What do you mean by mean? The mean number of bins or the mean of the variables that the histogram represents? For the second you...

Finding the mean of a histogram

What do you mean by mean? The mean number of bins or the mean of the variables that the histogram represents? For the second you...

plus de 2 ans il y a | 0

A répondu

How to compute the density of a 3D point cloud?

You can just directly apply the definition you gave considering that the density is N/Volume. The easiest is the second one, whi...

How to compute the density of a 3D point cloud?

You can just directly apply the definition you gave considering that the density is N/Volume. The easiest is the second one, whi...

plus de 2 ans il y a | 2

| A accepté

A répondu

Group array in a cell according to their size

A direct implementation could be done like this: A={[1 2 3 4] [4 5 6 9] [1 2 3] [7 8 9] [1 2] [3 4]}; sizes= []; for idx=1:...

Group array in a cell according to their size

A direct implementation could be done like this: A={[1 2 3 4] [4 5 6 9] [1 2 3] [7 8 9] [1 2] [3 4]}; sizes= []; for idx=1:...

plus de 2 ans il y a | 1

| A accepté

A répondu

How to fit one variable data into multiple ode equations

What you mean by y(1)? That you have data only for the first variable y1? Your equations seem to be coupled, so if you optimize ...

How to fit one variable data into multiple ode equations

What you mean by y(1)? That you have data only for the first variable y1? Your equations seem to be coupled, so if you optimize ...

plus de 2 ans il y a | 0

| A accepté

A répondu

How write these equation in Matlab for optimization

First you don't need the variable w, your problem is to maximize corr(Q,S), which is a unconstrained problem in x. Second, by yo...

How write these equation in Matlab for optimization

First you don't need the variable w, your problem is to maximize corr(Q,S), which is a unconstrained problem in x. Second, by yo...

plus de 2 ans il y a | 0

| A accepté

A répondu

Evaluate Function at different data points from vectors

Use meshgrid to generate all combinations and make your function accept vector entries. Ex: f = @(x,y,z)x.*y+z; % Insert your ...

Evaluate Function at different data points from vectors

Use meshgrid to generate all combinations and make your function accept vector entries. Ex: f = @(x,y,z)x.*y+z; % Insert your ...

plus de 2 ans il y a | 0

| A accepté

A répondu

Fit two peak model

You can estimate a continious function from your data using ksdensity and then fit two gaussians on it. My answer for the follow...

Fit two peak model

You can estimate a continious function from your data using ksdensity and then fit two gaussians on it. My answer for the follow...

plus de 2 ans il y a | 2

| A accepté

A répondu

Work with signals, frequency spectrum and frequency domain

This version of your code should do what you expect. After the loop I wrote an example of how to go to the frequency domain %% ...

Work with signals, frequency spectrum and frequency domain

This version of your code should do what you expect. After the loop I wrote an example of how to go to the frequency domain %% ...

plus de 2 ans il y a | 2

A répondu

How can I stop fminsearch in one iteration after a specific time?

If when you say stop you mean it simply freezes and you don't get an error nor the iteration goes on than you probably have some...

How can I stop fminsearch in one iteration after a specific time?

If when you say stop you mean it simply freezes and you don't get an error nor the iteration goes on than you probably have some...

plus de 2 ans il y a | 0

A répondu

i wan to generate the random number between two number with condition

If your second column has values equal to 40% of the first, then they are not random. You can vectorize this in the following fo...

i wan to generate the random number between two number with condition

If your second column has values equal to 40% of the first, then they are not random. You can vectorize this in the following fo...

plus de 2 ans il y a | 1

| A accepté

A répondu

How to determine the value of a matrix?

What you have is an integer matrix factorization problem, which is a rather complex topic. Main points that you have to take in ...

How to determine the value of a matrix?

What you have is an integer matrix factorization problem, which is a rather complex topic. Main points that you have to take in ...

plus de 2 ans il y a | 0

| A accepté

A répondu

matlab code for musical note recognition based on frequency

To really undestand the method, first try to define how exactly you gonna get the frequencies. Your main steps are : Define you...

matlab code for musical note recognition based on frequency

To really undestand the method, first try to define how exactly you gonna get the frequencies. Your main steps are : Define you...

plus de 2 ans il y a | 0

| A accepté

A répondu

Converting Cartesian Coordinates to Binary image

This is an general example you could use: Cartesian = [ 10,1; 15,10]; imSize=20; binaryImage= false(imSize)...

Converting Cartesian Coordinates to Binary image

This is an general example you could use: Cartesian = [ 10,1; 15,10]; imSize=20; binaryImage= false(imSize)...

plus de 2 ans il y a | 0

A répondu

chirp plot(i dont know what`s wrong plz help me)

Your code had some errors in respect to element-wise operator (^ instead of .^). Also you use the old time variable for the seco...

chirp plot(i dont know what`s wrong plz help me)

Your code had some errors in respect to element-wise operator (^ instead of .^). Also you use the old time variable for the seco...

plus de 2 ans il y a | 0

A répondu

How to Adjust x axis plot values in Matlab?

Use the xticks and xlim functions: M= [0.47 0.49 0.50 0.50 0.51 0.51 0.51 0.51 0.51 0.52 ]; Range= 5:2:23; plot(Ran...

How to Adjust x axis plot values in Matlab?

Use the xticks and xlim functions: M= [0.47 0.49 0.50 0.50 0.51 0.51 0.51 0.51 0.51 0.52 ]; Range= 5:2:23; plot(Ran...

plus de 2 ans il y a | 0

| A accepté

A répondu

Smoothed daily count of each column by applying a moving average filter of length 7

If your table has numeric values, then: c=T{:,6}; yy=smooth(c,7) If your table has string values that should represent numeri...

Smoothed daily count of each column by applying a moving average filter of length 7

If your table has numeric values, then: c=T{:,6}; yy=smooth(c,7) If your table has string values that should represent numeri...

plus de 2 ans il y a | 0

A répondu

7x7 arithmetic mean filter

You can colvolve the image with a filter that will perform the average. In your case it will be something like this: I = randn(...

7x7 arithmetic mean filter

You can colvolve the image with a filter that will perform the average. In your case it will be something like this: I = randn(...

plus de 2 ans il y a | 1

A répondu

Finding values corresponding to row and column index of a matrix

Have a look at the sub2ind function: A = [1 12 23 19 1 13; 2 3 13 34 5 75; 5 22 45 5 1 94; 4 5 68 2 5 17; 2 4 34 1...

Finding values corresponding to row and column index of a matrix

Have a look at the sub2ind function: A = [1 12 23 19 1 13; 2 3 13 34 5 75; 5 22 45 5 1 94; 4 5 68 2 5 17; 2 4 34 1...

plus de 2 ans il y a | 0

| A accepté

A répondu

Signal audio - effect downsampling ?

What exactly do you want to achieve? You see, downsampling the signal alone doesn't increases the frequency of it. This effects ...

Signal audio - effect downsampling ?

What exactly do you want to achieve? You see, downsampling the signal alone doesn't increases the frequency of it. This effects ...

plus de 2 ans il y a | 1

A répondu

how to extract variables from cell (dot operators)

You don't need to pre allocate since the best models are already in your cell array. I believe what you want may be something li...

how to extract variables from cell (dot operators)

You don't need to pre allocate since the best models are already in your cell array. I believe what you want may be something li...

plus de 2 ans il y a | 1

| A accepté

A répondu

I want to know how to overcome executable standalone app - image write path error?

The problem is the userpath function. As stated in the error, you can't modify a matlab path in your deployed application, regar...

I want to know how to overcome executable standalone app - image write path error?

The problem is the userpath function. As stated in the error, you can't modify a matlab path in your deployed application, regar...

plus de 2 ans il y a | 0

| A accepté

A répondu

how to manipulate Recursive function parameters ?

You didn't post the whole function, but regardless of this: It is possible to call a function without passing all the parameters...

how to manipulate Recursive function parameters ?

You didn't post the whole function, but regardless of this: It is possible to call a function without passing all the parameters...

plus de 2 ans il y a | 1

| A accepté

A répondu

Finding the point before landing

You used the function, not the calculated variables to find the index. Your point definiton was also a bit off. This version of ...

Finding the point before landing

You used the function, not the calculated variables to find the index. Your point definiton was also a bit off. This version of ...

plus de 2 ans il y a | 0

A répondu

How to produce a scatter plot with smooth line for this plot?

Those smooth lines are interpolations between the given points. For you to have a similar result, what you need to do is find an...

How to produce a scatter plot with smooth line for this plot?

Those smooth lines are interpolations between the given points. For you to have a similar result, what you need to do is find an...

plus de 2 ans il y a | 0

| A accepté

A répondu

Not enough input arguments.

Your Model_Inc function is not correct written, since it always return zero for a dummy variable you created in the beggining. I...

Not enough input arguments.

Your Model_Inc function is not correct written, since it always return zero for a dummy variable you created in the beggining. I...

plus de 2 ans il y a | 0

A répondu

keep element greater than immediate previous element

This loops does what you want: x = [1 2 3 4 3 2 3 4 6 8 5 5 6 8.5 9 11 12 ]; m = length(x); keep = [x(1)]; discard =[];...

keep element greater than immediate previous element

This loops does what you want: x = [1 2 3 4 3 2 3 4 6 8 5 5 6 8.5 9 11 12 ]; m = length(x); keep = [x(1)]; discard =[];...

plus de 2 ans il y a | 0

| A accepté

A répondu

fmin additional variables ( are vector)

Your first attempt was right [X fval exitflag output lambda grad hessian] = fmincon(@(x) fun(x,g_14,k_4) , x0, A, b, Aeq, beq,l...

fmin additional variables ( are vector)

Your first attempt was right [X fval exitflag output lambda grad hessian] = fmincon(@(x) fun(x,g_14,k_4) , x0, A, b, Aeq, beq,l...

plus de 2 ans il y a | 1

| A accepté

A répondu

Store user input data into matrix

Your loop position was wrong and you should save values as strings, not cells. This version of your code works: n=2; filename=...

Store user input data into matrix

Your loop position was wrong and you should save values as strings, not cells. This version of your code works: n=2; filename=...

plus de 2 ans il y a | 0

| A accepté

A répondu

How to solve a system of equations when multiple parameters changes

A for loop work, maybe you had some trouble with the indexes w_1=[1,2]; w_2=[2,3]; w_3=[3,3]; w_4=[4,5]; w_5=[5,6]; w_6=...

How to solve a system of equations when multiple parameters changes

A for loop work, maybe you had some trouble with the indexes w_1=[1,2]; w_2=[2,3]; w_3=[3,3]; w_4=[4,5]; w_5=[5,6]; w_6=...

plus de 2 ans il y a | 0

| A accepté