Réponse apportée
Differential Operator in Matlab in 1 Dimension
I'm not a math major so there's probably something technically wrong about this statement, but "d/dx" is essentially "dy/dx", re...

environ 4 ans il y a | 1

Réponse apportée
Find the number of red marks in box plot
One method, which may not necessarily correlate to a boxplot in all situations (but probably works for the default boxplot), is ...

environ 4 ans il y a | 0

| A accepté

Réponse apportée
geting matlab installer to start on linux
From a comment deep in the thread (here), and from reading your symptoms, what typically works with this version of Ubuntu is: ...

environ 4 ans il y a | 2

| A accepté

Réponse apportée
Converting datenums to get time durations
I don't see where WaveHeight is declared, but you can calculate a duration by subtracting datetimes. ThreshDate = datetime('now...

environ 4 ans il y a | 0

Réponse apportée
How can I identify the amplitude peaks from an FFT?
You can use findpeaks, probably with some additional parameters. For instance, if the plotted signal is P: Z = findpeaks(P,'Min...

environ 4 ans il y a | 0

| A accepté

Réponse apportée
IF Statement Help?
This statement would flow like this, for a 30-degree angle (in pseudocode): if CurrentPosition < 45 % True, so... wri...

environ 4 ans il y a | 0

Réponse apportée
Help with a tiny project ( building a graph)
If I understand correctly, you only wish to plot I as a function of x. I have modified your function slightly (at the end of t...

environ 4 ans il y a | 1

| A accepté

Question


Why are alternative forms for "dbstop in file at location if expression" not documented?
This question is prompted by another question here. It was fairly easy to guess that dbstop('file','10') would set a breakpoi...

environ 4 ans il y a | 1 réponse | 1

1

réponse

Réponse apportée
Use variables in dbstop
dbstop(file,num2str(line)) Usually, functions that have input forms like dbstop has can also be called like a normal function...

environ 4 ans il y a | 1

| A accepté

Réponse apportée
A better way to do antidiagonal matrix vectorization?
I believe this works for tall arrays and square arrays. I haven't yet figured out how to compensate if N>M. It's not as fast as...

environ 4 ans il y a | 1

Réponse apportée
A question about the efficiency of matrix multiplication in MATLAB.
Matlab was built to do matrix math first, with the highly optimized LAPACK library at its heart. That's what it's using for case...

environ 4 ans il y a | 0

Réponse apportée
How can I average same-calendar-month returns over the prior 20-year period?
This is a complex question. I would answer your questions with a cell array of tables, and a whole lot of untested (because I d...

environ 4 ans il y a | 0

| A accepté

Réponse apportée
How do i write a line to display all the values that didn't meet the requirement
SigmaAp = 5; SigmaAx = randi(9,5,1) idxs = find(SigmaAx>SigmaAp) disp('Values over the limit:');disp(SigmaAx(idxs))

environ 4 ans il y a | 0

| A accepté

Réponse apportée
How to read GSI (text) file?
A = readlines('Example_of_GSI.txt'); parsed = split(A).strip('*'); Does that break it down enough for you to work with?

environ 4 ans il y a | 0

| A accepté

Réponse apportée
I need to find a pattern in a column
A = readmatrix('test.xlsx'); count = 0; for idx = 1:numel(A)-34 if sum(A(idx:idx+34)) == 0 count = count+1; ...

environ 4 ans il y a | 0

| A accepté

Réponse apportée
Livescript results in incorrect Math output
The commented-out line is: lambda_j + 2*rp*max(subs(g1,[x1;x2],x), -lambda_j/(2*rp)) lambda_j is 1. The second term (which use...

environ 4 ans il y a | 0

Réponse apportée
Why shift, take absolute value and perform log transform to the frequency spectrum of an image obtained by fft2?
take the absolute value The log of a negative number is undefined, which would make for a boring image. apply a log transforma...

environ 4 ans il y a | 0

Réponse apportée
Store values from a for loop in matrix and plot them.
You need an index to keep track of your loop iterations. You can do this one of two ways: idx = 0 for Prc = Prc=7:1:27 idx = ...

environ 4 ans il y a | 0

| A accepté

Réponse apportée
How to draw a surface starting from a 3 column vector X, Y, Z with no regular grid on X, Y ?
Another useful function is griddata

environ 4 ans il y a | 0

Réponse apportée
changing the time zone for two datetime objects then comparing them
t.Date3.TimeZone = 'Asia/Dubai'; d.date.TimeZone = 'Asia/Dubai'; Works for me.

environ 4 ans il y a | 0

Réponse apportée
convert python code to MATLAB
With Mie.py in your Matlab path and pyenv set up correctly, do: mie = struct(py.Mie.MieQ(1.525+0.0011j,450,300,pyargs('asDict',...

environ 4 ans il y a | 0

Réponse apportée
Contour plot omitting certain points
If it bothers you, you can set caxis(min_lim,max_lim). You can include more levels by indicating the number in the function cal...

environ 4 ans il y a | 0

| A accepté

Réponse apportée
Increase the height (size) of subplots
If you have 2019b or newer, you can use a tiledlayout. It doesn't really show here, but there's a difference. https://www.mathw...

environ 4 ans il y a | 1

Réponse apportée
How can I identify only the first or first two local minima from "islocalmin" and then display it in a table on a plot?
% Find the index of the first minimum TF=find(islocalmin(VarName2),1); % Get the values for the lower and upper curves lowerV...

environ 4 ans il y a | 0

| A accepté

Réponse apportée
How to remove outliers in a 3D surface
I would recommend trying the "clean outlier data" task in the live editor, after sorting the data: T = sortrows(T,1); % Sort by...

environ 4 ans il y a | 0

Réponse apportée
how can i save the even index to a matrix 2:5 using for loop
z=randi([1 10],5,10) newmatrix = []; for i=1:5 if(mod(i,2)==0) for j=1:10 if(mod(j,2)==0) % ...

environ 4 ans il y a | 1

Réponse apportée
How to make a contour plot with incomplete z data?
As far as I understand, you'll need a rectangular array representing the grid of intensity values. If your grid is square and yo...

environ 4 ans il y a | 0

Réponse apportée
my while statement wont work
It looks like you need to reset Err to 1 after a loop completes.

environ 4 ans il y a | 0

Réponse apportée
Question about finding the number of times an element appears in an array
A = randi(9,2) A(:) formats A in a column vector. A(:) A(:)==c compares the column to each element of c (possible because th...

environ 4 ans il y a | 0

| A accepté

Réponse apportée
Find the standard error of the mean for each column in a matrix containing NaN and numerical values
That's a 4x4 matrix, not 5x4. The default behavior or nanmean and nanstd is to give you the statistic for each column. Taking t...

environ 4 ans il y a | 0

| A accepté

Charger plus