Answered
Sgolay filter is reducing the peal pulse too much.
Use a low-value order (I usually use 3) and experiment with different values for the frame length.

4 years ago | 0

| accepted

Answered
Symbolic Paramaters Not Supported in Nonpolynomial Equations
Solve it once, generate numeric functions, then evaluate the functions. % for t = 1:100 syms U_dot U W W_dot M_a theta ...

4 years ago | 0

Answered
I keep getting the solve stops prematurely for fsolve?
Possibly — % ------ Guess --> Range of AOA ------ % opts = optimoptions('fsolve', 'MaxIterations', 5E+3); ...

4 years ago | 1

Answered
Finding student t critical value...
@Sabina Yasmin — Your question implies that you do not have the tinv function. The t distribution and inverse t distributio...

4 years ago | 0

Answered
Creating a datetime variable - unconventionally
Using months instead of minutes — Date = {'200301'; '200306'; '200312'} DateDT = datetime(Date, 'InputFormat','yyyyMM') Date...

4 years ago | 0

| accepted

Answered
Implementation of the goertzel FFT
See if the goertzel function will do what you want. Also see DFT Estimation with the Goertzel Algorithm for an application ex...

4 years ago | 0

Answered
why does the output show % when i type fprintf('%%')
In the documentation section on formatSpec see the section on Text Before or After Formatting Operators.

4 years ago | 0

| accepted

Answered
How can I make plot lines different colors when solving PDE?
There are problems referenceing ‘u’ and ‘v’ since they are both (9x2001) matrices, so to be comkpatible with ‘x’ address the ro...

4 years ago | 0

| accepted

Answered
how to get the contour/shape of a representation in 2D?
Another approach — LD1 = load('x.mat'); x = LD1.x; LD2 = load('y.mat'); y = LD2.y; cntrd = mean([x(:) y(:)]); ...

4 years ago | 1

| accepted

Answered
How to select the column of matrix?
Try this — M = randn(10,5) % Create Matrix Mv = vecnorm(M) [mxMv,col] = max(Mv) Des...

4 years ago | 0

| accepted

Answered
Add grid lines onto the 3D mesh plot
Use the Surface Properties MeshStyle property — [X,Y,Z] = peaks(50); figure hs = surf(X,Y,Z); hs.MeshStyle = 'column'; ...

4 years ago | 0

Answered
Starting my x-axis values not from zero
‘Trying to start x-axis which is my current density(j) values from the value 7e-3. Can anyone help out with this.’ Probably n...

4 years ago | 0

Answered
How to plot all contour lines in one plot?
Specify them as a single levels vector — [X, Y, Z] = peaks(50); figure contour(X, Y, Z, [-4.34, -4.3, -4.2, -4.1, -4, -3, ...

4 years ago | 0

| accepted

Answered
how to floor time for each hour?
Try this — tv = {'12-Dec-2021 09:09:04' '12-Dec-2021 09:24:04' '12-Dec-2021 09:39:04' '12-Dec-2021 09:54:04'...

4 years ago | 0

| accepted

Answered
I am having trouble using lsqcurvefit with an function
Experiment with different values for ‘x0’ since nonlinear parameter estimation routines are very sensitive to the initial parame...

4 years ago | 0

Answered
How to determine the exact intersection between line and two curves
Try this — LD = load(' matlab.mat'); p1 = LD.p1; p2 = LD.p2; x = linspace(0, numel(p1)-1, numel(p1)); idx = find(diff(si...

4 years ago | 0

| accepted

Answered
how to determine the actual location of the spectral peaks using the built-in MATLAB function, fminbnd.
Here is an example of how to get and plot the peak values and locations using the Signal Processing Toolbox findpeaks function —...

4 years ago | 0

| accepted

Answered
Put heatmap color bar on top
See the Location property of the colorbar in Colorbar Properties. That should work. (I rarely use heatmap objects so I canno...

4 years ago | 0

Answered
How to interpret "F-statistics vs. constant model" in the fitnlm function?
That is the probability that the model explains the data better than the mean of the data. The ModelFitVsNullModel property doe...

4 years ago | 0

| accepted

Answered
How can I create a 3D graph with a color map in the range from 0 to 1 ?
Another approach — xg = X_achse_of_geometrie + output_array; yg = Y_achse_of_geometrie + output_array; zg = Z_achse_of_geome...

4 years ago | 0

| accepted

Answered
Splitting Data Into Intervals and Finding the cumulative value
Try this — a = [1.0000 71.8700 2.0000 136.1100 3.0000 151.3500 4.0000 139.1300 5.0000 127.1900 ...

4 years ago | 0

| accepted

Answered
How to plot 2 plots in one for loop with each plot having a legend
Try something like this — x = 1:1:10; y = zeros(10,5); figure; Ax1 = axes; hold on figure Ax2 = axes; hold on fo...

4 years ago | 1

| accepted

Answered
How to add, multiply and subtract two matrices have different length ?
While adding two matrices of different dimensions is not defined mathematically, it is possible to add or subtract them by index...

4 years ago | 0

| accepted

Answered
Taking an inverse spatial fft in MATLAB
The question is a bit ambiguous, and I do not have the frequency and complex amplitude vectors to work with. For a one-sided ...

4 years ago | 0

| accepted

Answered
importdata() function problem
It would be helpful to know what ‘not working’ actually means. Assuming that ‘filelist’ is a cell array, perhaps: filename ...

4 years ago | 0

Answered
How to add contour plot to xz and yz surface to 3d plot
I am not certain what the desired result is. Try this — LD = load('matlab.mat'); figure surf(LD.x, LD.y, LD.V0) hold o...

4 years ago | 0

| accepted

Answered
How do i fit a histogram properly?
Using chi2gof to assess curve fitting of a regression may not be appropriate. T1 = readtable('https://www.mathworks.com/matl...

4 years ago | 0

Answered
I have a program and I need to make a model of it.
My guess is that the code now needs to be made into an objective function to be used with a parameter estimation routine. See...

4 years ago | 1

| accepted

Answered
datetime to string conversion
Ise the 'Format' name-value pair — dayv = datetime(2008,04,01, 'Format','yyyyMMdd') string(dayv) .

4 years ago | 0

| accepted

Answered
Why do I recieve an error "Index in position 1 exceeds array bounds" ?
Try this — desiredlength = 1; % Cut the yEdited audio file to 1 second (First One Second) L = Fs * desired...

4 years ago | 1

| accepted

Load more