Answered
Extract data from matlab default plots
Call it with as many outputs as you need, then use the outputs in your subsequent calculations: [frf,f,coh] = modalfrf(___) Y...

8 years ago | 0

| accepted

Answered
Why does 'lowpass' give me an error?
The lowpass function was introduced in R2018a. You can easily design your own filter if you are using 2017b or earlier. A ...

8 years ago | 1

| accepted

Answered
Error using / Matrix dimensions must agree. (tried using .* and ./)
You need to vectorise the division, using ./ instead of /. This works: r=[100:100:1000] %ohms c=1e-06; %farads l=0.64; %h...

8 years ago | 0

| accepted

Answered
How to insert 5ms rise and fall to my signal (sound) ?
Try this: Fs = 44100*2; % Sampli...

8 years ago | 0

| accepted

Answered
Mesh plot axis description
Use the 'XTick' (link) and 'XTickLabel' (link) properties to define the tick values and tick labels. Note that you need to use ...

8 years ago | 1

| accepted

Answered
estimate the parameters of lognormal distribution by the some values of CDF
Try this: fcn = @(b,x) cdf('Lognormal',x,b(1),b(2)); x= [0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.55 0.60 0.6...

8 years ago | 1

Answered
Finding each maximum and minimum value of a sinusoidal function
That depends on the sinusiodal function and your constraints. Use the max function to find the first maximum and its index, t...

8 years ago | 0

Answered
Matlab function equivalent to seqa()
If you are talking about this: x = seqa(start, step, count);creates a sequence of 'count' numbers starting at 'start' and incr...

8 years ago | 0

| accepted

Answered
MATLAB plot: bring a line in front of an area
One option is to reduce the 'FaceAlpha' of the area plot: h.FaceAlpha = 0.5;

8 years ago | 0

| accepted

Answered
How to determine modes of vibration using FFT?
I would do something like this: filename = 'soundbooth_rawdata.xlsx'; [D,S] = xlsread(filename); t = D(:,1); s = D(:,2); T...

8 years ago | 0

| accepted

Answered
how to plot graph
result = [1 2 3 4 5 6 7 8 9 10 11 12]; time = [1 2 3 4]; figure plot(time, result)

8 years ago | 0

Answered
How to obtain ORIGINAL columnar indexes of top 3% values.
Another option, using the maxk function (introduced in R2017b): x = rand(100, 3); % Create D...

8 years ago | 0

Answered
How to cut out specific segment from findpeaks function?
You can get the ‘Borders’ x-coordinates using: (Previous Code) findpeaks(PeakSig,x,'Annotate','extents','WidthReference','hal...

8 years ago | 0

| accepted

Answered
What is the meaning of "width" and "prominences" in findpeaks
Is the w is the width (half-height) and p is height as pointed in the plot? Your interpretation of ‘p’ is correct. The value...

8 years ago | 1

| accepted

Answered
how to replace Table_A withTable_B based on their corresponding date?
I would first convert the tables to the timetable (link) data type (that means you will have to convert your three date columns ...

8 years ago | 0

| accepted

Answered
Using loop to solve a summation
No, because you need to subscript ‘m’ and sum ‘x’ in each iteration. However you do not need the loop: m=0:1200; x=sum(1./...

8 years ago | 1

Answered
Function with sum of vector elements
You need to pass ‘A’ and ‘B’ as arguments to your funciton: function [ f_intensity ] = FT_g( f, A, B ) Then call it the same ...

8 years ago | 0

Answered
at what data rate should i take values? and how to code for it
For cardiovascular data (including EKG) recording, the minimum sampling frequency is generally considered to be 250 Hz, giving a...

8 years ago | 0

Answered
Problem reading data from Excel sheet.
The person (or application) that wrote the Excel file may not have done it correctly. If the numeric data (the first output of ...

8 years ago | 0

Answered
Why won't anything plot? 6 errors in 3 lines of code.
It’s always worth running these commands: restoredefaultpath rehash toolboxcache from your Command Window (or a script) bef...

8 years ago | 4

Answered
How to solve this system of ODE's
Your ODE funciton has to have your independent and dependent variables (here ‘t’ and ‘x’) as arguments. Try this: function ...

8 years ago | 0

| accepted

Answered
How to delete elements considered in a loop?
I am not certain what you are doing or what your arrays are. However, the ismembertol (link) function is likely the function th...

8 years ago | 0

Answered
Hi , please how to make a loop for subplot , I need to plot plot 5 signals on 3 rows & 2 columns , signals to plot x , y , cr_x , cr_y and cr_xy given below in the code for auto-correlation and cross-correlation
I doubt that a loop would be more efficient than simply allocating the subplot calls using your existing code. Try this: fi...

8 years ago | 0

| accepted

Answered
Find coefficients after rearranging harmonic terms
Try this: syms A11 A12 A21 A22 B1 B2 A0 B0 A1 B1 C1 D1 w t Ps Pc km th(t) = A0*cos(w*t)+B0*sin(w*t)+B1*cos(2*w*t)+B1+C1*sin(...

8 years ago | 0

| accepted

Answered
fzero, because complex function value encountered during search
The ‘new error’ does not appear to be an error. The fsolve function encountered what appears to be a global minimum (or at leas...

8 years ago | 0

| accepted

Answered
Fill the region between two lines
Use the patch (link) function: x=0:0.1:10; y1=exp(-x/2); y2=exp(-x/3); figure hold all plot(x,y1) plot(x,y2) patch([x f...

8 years ago | 7

| accepted

Answered
How to remove for loops from this code
I’m not certain what you want to do, although my best guess is that you want to convert your polar coordinates to Cartesian. ...

8 years ago | 0

Answered
How do I find similar columns in a matrix?
I would use the pdist (link) function. It will compare the columns of your data using one of the built-in distance metrics, or ...

8 years ago | 0

| accepted

Answered
Why is my sum outputting a curly bracket?
You are attempting to combine strings and numeric data. That will not work. Try this: disp(['Sum of even numbers from 2 to...

8 years ago | 0

| accepted

Answered
How to obtain matrix components
You need to enclose the variables you are solving for in square brackets: [EL,vlt,vtl,ET,GLT] = solve(y,[EL,vlt,vtl,ET,GLT]); ...

8 years ago | 0

| accepted

Load more