How to to report row at which the difference reaches below a threshold?
Probably the hardest part will be defining the exact rule for "sufficiently small difference". After that, I think something lik...

12 days ago | 0

| accepted

Take values from a matrix, line by line.
I would do this as follows: WDV = exp(A.'); and any time later I need to refer to "W", I would reference WDV(:,1). If you abs...

15 days ago | 0

| accepted

Unable to debug the problem in the code.
I'm guessing it's a problem with floating-point precision when you do this comparison: (time-flag*carrier_time_period)== carrie...

15 days ago | 1

| accepted

how to change a number of base n to base m
John D'Errico created the base2base function to do exactly this. Follow that link to the File Exchange. >> base2base('124',10,5...

15 days ago | 0

| accepted

Weighted average between NaNs with movmean, determing window length?
You really lost me when you commented that the output would be a single value. How is that a moving average? Do you just want th...

15 days ago | 0

Weighted average between NaNs with movmean, determing window length?
If my guess above is correct, then input = [1, 3 ,2 ,5 , NaN, NaN, 1, NaN, NaN, NaN, NaN, 4, 4, 7, 1, 3, NaN, 2, 5, 2, 3]; [...

15 days ago | 0

how to make make matlab compute values of simple trignometric identities?
Do you mean you want to solve for theta, in the equation cos(pi/2 + theta)= - sin(theta); ? Use solve.

15 days ago | 0

This how i want the plot to be
Since you have spread similar questions across several places, without good organization (and one of them was closed), I'll post...

15 days ago | 0

Rolling Beta For Multiple x and y variables simultaneously
I believe this does what you intend. % Set seed for reproducibility rng default % Set a few convenience parameters N = 100...

15 days ago | 1

| accepted

Extracting a slice from a 4D matrix
If your 4-dimensional array is A, then the first slice can be extracted using sliceA = A(1,:,:,:); As you say, this will be a ...

16 days ago | 0

| accepted

maximum likelihood did not converge for gevfit
I don't know for sure, but my best guess is that the problem is the relatively small amount of data, coupled with the fact that ...

16 days ago | 1

| accepted

Fill an array with different size vectors
Here is one straightforward way: A=[1,2,3,4]; B=[5,6]; C=[7,8,9]; ARRAY=zeros(5); ARRAY(1,1:numel(A)) = A; ARRAY(2,1:nu...

16 days ago | 1

matlab for beginners and books
I suggest MATLAB Onramp.

17 days ago | 0

Can you cancel my email change permission?
You should contact support for that request, rather than using the Answers forum.

19 days ago | 0

Are you asking for help only for sending the message? I suggest you read this page from the great Undocumented Matlab web site. ...

20 days ago | 0

what can i add to this code to plot in 3d
You already have a 3-dimensional plot, but you did not create a grid with fine enough spacing. Try using this instead: x = 0 : ...

20 days ago | 1

how to Expanand any matrix
I am not certain I interpreted your question correctly, especially the "righth shift the column by ones times". But I believe th...

20 days ago | 0

Sum the component of a vector till a certain value
G(cumsum(G)<80)

21 days ago | 0

| accepted

How to Install New Versions
You should just be able to go to the downloads page of the MathWorks site. You do not need to uninstall your old version. (You ...

21 days ago | 0

| accepted

Mean and standard deviation of a field - condition on another field
The mean and standard deviation of f1, for the elements where 50 < f2 <= 100, can be calculated as follows: arrayfun(@(x)mean(x...

22 days ago | 1

Calculate the number of nonzero rows
Use any instead of all. Your code is counting rows in which all entries are non-zero.

23 days ago | 1

Deleting several specific columns from a table
Do you know all the column indices you want to delete? It's as simple as columnIndicesToDelete = [4 5 6 7 9 12 14 15 17]; % and...

23 days ago | 1

| accepted

How to generate realisations from two sets
L1 = length(S1); N1 = 2; S1(randperm(L1,N1)) will choose N1 numbers (in this case, 2) from S1. You can choose similarly fro...

24 days ago | 0

Matlab fit to three dimensions function
I would do it like this: % Set the random number generator seed, for reproducibility rng default % Create some random data ...

24 days ago | 0

extract specific values in a matrix
If A is your matrix: A(find(A(:,10)==0.03,1),10); You might need to be careful about getting an exact match with the floating-...

24 days ago | 0

| accepted

Is it possible to change PATH temporarily?
This is not really an answer to your question, but this documentation about identifying program dependencies might also be usefu...

25 days ago | 0

Connecting points between two box plots
I did not download notBoxPlot, but here is an example using a scatter plot instead. % Some pretend data N = 5; x = [randn(N,1...

26 days ago | 1

| accepted

How to draw an "error bar" between two points on a scatter plot
I think you might be able to get something pretty close to what you want using the doublearrow annotation. (There is a property ...

26 days ago | 0

| accepted