Answered
how to pick partial data from a waveform?
helloo this is my submission, hope it helps ! clc clear all close all data = readmatrix('test.txt',"NumHeaderLines",1)...

5 years ago | 1

Answered
Issue with Chirp function in Matlab
hello there are a few points that I don't understand : why 'complex' chirp signal ? we can only plot real signal the sampl...

5 years ago | 1

| accepted

Answered
How can I simulate the tension on the sensor?
hello as far as I can see, the Fb and Fg forces are given, only Fc is unknown. So you have to generate a range of values for F...

5 years ago | 0

| accepted

Answered
Error: "Dimension argument must be a positive integer scalar within indexing range" using trapz
hello Jacqueline with the given limits xi=5.67; xf=14.20; , idl contains only one valid x value , so trapz will throw an error,...

5 years ago | 0

| accepted

Answered
ODE to solve for density
hello as far as i can tell , the second plot is simply the derivative given by you and not the solution of the ODE hx = linsp...

5 years ago | 0

| accepted

Answered
How to write for or while loop along with indexing?
hello I modified a bit your code so that it will generate y and z cell arrays whatever the number of years. No manual code mod...

5 years ago | 0

| accepted

Answered
How to superimpose a pulse (like partial discharge pulse ) over a pure sine wave signal
hello this is a code to generate a gaussian pulse you can add this to your sine wave f0 = 2e3; Var_Sq = 1; Fs = 1e5; dt ...

5 years ago | 0

Answered
how do I take the matrix A and a vector with the indexes of the rows to be considered, and takes out a vector of the mean values?
hello title and question are not consistent: odd rows or odd columns ? result for odd columns : out = mean(A(:,1:2:end),1...

5 years ago | 0

Answered
How to plot quantized signal in MATLAB?
hello this little code snipset to illustrate what is sampling quantization is simply to round the y values to the nearest 2^...

5 years ago | 0

Answered
smooth the surf or pcolor graph
hello looking first at your data distribution (histogram(Z)) I noticed 90% of the data is between 15 and 300 , very few sampl...

5 years ago | 0

| accepted

Answered
How to find corresponding frequencies after viewing amplitude in descending order?
hello I modifed a bit your code and tested it with a two tone signal see the line with peak_fr_sorted_values clc %% dumm...

5 years ago | 0

| accepted

Answered
2d gaussian function
hello Lucy assuming your values are stored in A vector, use reshape to get the 848x480 pixels in matrix B : B = reshape(A,848...

5 years ago | 0

Answered
how to plot bar overall 1/3 octave by Poctave() as show below(bar color red)?
hello see example below : Fs = 44.1E3; xInp = rand(1,2^16); % Compute the octave spectrum of the same signal, but th...

5 years ago | 0

| accepted

Answered
Error when using sgolayfilt
hello Anna are you sure P1 is type double ? the code works on my side with dummy rand input P1 = randn(1112992,1); orde...

5 years ago | 0

| accepted

Answered
Dividing array to subarrays based on threshold
this is my 2 cent suggestion A=[0 1 2 3 4 3 2 1 0 1 1 2 3 7 8 4 3 2 1 0 1 2 4 8 9 6 3 2 1]; threshold = 2; ind = find(A>=t...

5 years ago | 0

Answered
How can I use loop to produce multiple graphs?
hello Daphne I modified a bit your code - see the comments only issue for me in line : Monthly_Temp = accumarray(Hindd_ck,...

5 years ago | 0

| accepted

Answered
Excursion of loudspeaker model is drifting massivly
HELLO I think I have an idea of where the problem lies... I first had a look how the non linear BL and suspension force equati...

5 years ago | 0

| accepted

Answered
How to smooth plot without affecting the data. While I used smooth in plots, the data was reduced at some points.
hello to have a smoothed curved that goes closer to your input points, you have to interpolate first to have more data points,...

5 years ago | 0

| accepted

Answered
I get my peaks at the wrong frequency and with the wrong amplitude.
hello Anna look at my fft function at the end of my code clc %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % load signal %%%%%%%%%%%...

5 years ago | 0

| accepted

Answered
Non-linear Curve Fitting Issue with Experimental Data
HELLO I don't have the CF Toolbox but I could manage to get a reasonnable good fit by using 4th ordre polynomial fit on log lo...

5 years ago | 1

| accepted

Answered
Bandpass filter vs sequential high and lowpass filter in Matlab: weird difference
I prefer this code ... faster and I know what filters I use i changed the input signal random + negative constant (to mimic you...

5 years ago | 0

| accepted

Answered
How to remove the mean from a data
hello you can simply do a = a - mean(a); NB : you can also use the detrend function

5 years ago | 0

| accepted

Answered
1/f amplitude spectrum and slope
hello Mercede Slightly modified code, simply give it a valid wav file name - it works as can be seen below - or where is your...

5 years ago | 0

| accepted

Answered
Creating a for loop that generates sound when given mean and standard deviation of frequency
hello Isabelle chek this ... you have now four wave files in your directory with different frequency beeps signals hope it hel...

5 years ago | 0

| accepted

Answered
50 Hz interference and noise reduction from ECG.
hello If you want only to remove the 50 Hz tone , use a notch filter as shown in example below. I used your data and guessed t...

5 years ago | 0

| accepted

Answered
spectrograme using STFT(DSP)
hello I was not comfortable with how you defined the basics constants in your code , so I rewrote it my way - I believe more r...

5 years ago | 0

| accepted

Answered
ERROR WHILE UPLOADING CSV FILE MANUALLY(BY IMPORT METHOD)
hello no issue found with your file . Could load it with readtable T = readtable('feed.csv'); T = 12×3 table ...

6 years ago | 0

Answered
Average of every n values in a matrix.
hello see 2 examples below , without and with overlapping sections % dummy data data = rand(320,15); buffer = 5; % nb of...

6 years ago | 0

| accepted

Answered
Remove leading blank space from specific lines in .txt files
hello my suggestion below , tested on following text (I added a last section for my testing purposes) Start; ...

6 years ago | 0

| accepted

Answered
How to create separate tables from a data set
hello here below my suggestion to split the large csv file into smaller txt files they may be smarter use of regexp but this...

6 years ago | 1

Load more