Answered
Different values obtained from same function file on different computers
There are many reasons why calling the same function file twice with the same inputs may return different answers. The most comm...

8 years ago | 0

Answered
Can I make matlab not show the type after a command in the command line?
This change was <https://www.mathworks.com/help/matlab/release-notes.html?rntext=header&startrelease=R2016b&endrelease=R2016b&ca...

8 years ago | 0

Answered
Solve Command for Unknown Parameters
Let's see how your function looks in a neighborhood around y = 0. f = @(beta) 7*exp(-0.008*beta)+0.008*sin(7*beta)-7*cos(7*...

8 years ago | 0

| accepted

Answered
ode15s extract solutions for every time step
There's no mistake. From the description of the tspan input argument on the <https://www.mathworks.com/help/matlab/ref/ode15s.ht...

8 years ago | 0

| accepted

Answered
Plot range of values as bars
It sounds like you want the <https://www.mathworks.com/help/matlab/ref/errorbar.html |errorbar| function>.

8 years ago | 0

Answered
double precision becomes complex double after calculation
-1 is real. 0.5 is real. (-1)^(0.5) is complex. There's nothing _to_ "fix" as that's the expected behavior. If you want MATLA...

8 years ago | 1

| accepted

Answered
Is equality == available in Matlab 2017 ?
I'm fairly certain the == operator has been part of MATLAB since Cleve's original version. [If not, it was introduced not long a...

8 years ago | 1

Answered
How to get yr, month, day, hr, min and s stored as separate variables from a serial date number?
That's close to what you get using the Excel |datetime| type, but not quite. >> D = datetime( 37987.0108217593, 'ConvertFro...

8 years ago | 0

| accepted

Answered
Swap 3 random elements in an array
Use |randperm| to select 3 elements (without replacement) from your vector. a = [4 2 3 1 5 7 6] ind = randperm(numel(a),...

8 years ago | 2

| accepted

Answered
Unit testing: Check result of e.g. verifyEqual
For your specific use case of entering debug mode when a verification failure occurs, add the <https://www.mathworks.com/help/ma...

8 years ago | 1

| accepted

Answered
How to add variables in workspace with names derived from a char array and corresponding values stored in a double array
Instead of dynamically creating variables, I recommend creating a |table| array. The variables (columns) in a |table| are named ...

8 years ago | 1

Answered
Get in Order respond when using "eig" command
The "Sorted Eigenvalues and Eigenvectors" example on the <https://www.mathworks.com/help/matlab/ref/eig.html documentation page ...

8 years ago | 0

Answered
How to create new column formula that references other tables?
>> load patients >> patients = table(LastName,Gender,Age,Height,Weight,Smoker,Systolic,Diastolic); >> patients.W_H = pat...

8 years ago | 0

Answered
[Beginner] How do you make a summary table?
Try using <https://www.mathworks.com/help/matlab/ref/groupsummary.html |groupsummary|> on your larger |table| with the data read...

8 years ago | 1

| accepted

Answered
What is the difference between the Distrib_Comp_Engine and Distrib_Computing_Toolbox licenses?
Originally, the product now known as Parallel Computing Toolbox was named Distributed Computing Toolbox. Similarly, MATLAB Distr...

8 years ago | 4

| accepted

Answered
Non uniform circle marks on line plot
Use the MarkerIndices property <https://www.mathworks.com/help/matlab/release-notes.html?rntext=MarkerIndices&startrelease=R2015...

8 years ago | 0

Answered
function hist3 number of bins with 'Edges' option doesn't count the bins right
Instead of using |hist3| I recommend you use |histogram2|.

8 years ago | 0

Answered
Is there a simple way to convert all fields of a struct to local variables?
_I have a matlab program with a lot of variables (boolean, arrays, doubles, logicals, strings), to the point where it becomes un...

8 years ago | 1

| accepted

Answered
create timeseries from first january to 31. December
I don't believe that's possible. How many days long is the vector from January 1st to December 31st? That's a simple question, r...

8 years ago | 0

Answered
'Cannot call or index into a temporary array' error message when setting up a set of coupled odes for ode45.
_Let y be a function of t, y = y(t). The the ode has a term like this:_ _dy/dt = (arbitrary function of time)*y(t-epsilon), w...

8 years ago | 1

| accepted

Answered
What means : Error using sparse Index exceeds array bounds.
Show us the output of this command: nnz(edges > num_modes) The output will likely be nonzero. If that's the case it indi...

8 years ago | 0

Answered
Changing static node to random distribution node.
So you want to select a random subset of the possible edges to be included in your |graph|? Consider using the |sprandsym| funct...

8 years ago | 0

| accepted

Answered
How do I integrate Git source control with Matlab?
Which release are you using? Support for Git in the Current Folder browser was introduced in <https://www.mathworks.com/help/mat...

8 years ago | 0

Answered
Error: "Difference order N must be a positive integer scalar"
[t,y] = ode45(DE, [0 10], 0); After the first iteration through your |for| loop, y is no longer a symbolic function. It was...

8 years ago | 0

| accepted

Answered
Is there a way to plot a contour with a 3-Dimensional matrix?
I'm not certain, but from your description I think you might want an |isosurface|.

8 years ago | 0

Answered
How to exclude bins from a bi-variate histogram
Don't eliminate data points from your xpos and ypos arrays. Instead, specify XBinLimits and YBinLimits when you call |histogram2...

8 years ago | 0

Answered
Unable to Plot in For Loop
It looks like TempFile is the name of a file that you want to read into MATLAB, but you skipped the actual file reading step. ...

8 years ago | 0

Answered
Plotting XY origin XY destiny
The first function that comes to mind based on the picture is |quiver|, though I'm not completely certain from your description ...

8 years ago | 1

Answered
How to evaluate a function over a range of inputs
You will need to use the element-wise or array versions of the division and power operators. See <https://www.mathworks.com/help...

8 years ago | 0

Answered
if condition based on coefficients/problem parameters of cfit
Use the <https://www.mathworks.com/help/curvefit/coeffnames.html |coeffnames| function>.

8 years ago | 0

Load more