Answered
how do you calculate frequency of squarewave
hello you can try this code % dummy data n = 10000; x = 25*(0:n-1)/n; y = sign(sin(x+0.25*x.^2)); threshold = 0.5*ma...

24 days ago | 0

| accepted

Answered
Storing data in columns not in rows
hello why not use a structure or a table ? it's much appropriate when dealing with variable size data sets % Define initial...

25 days ago | 0

Answered
Dimensions of arrays being concatenated are not consistent.
hello this is my suggestion get the data simply by this command : data = str2num(Lines(2)); myFolder = 'mydrive'; f...

25 days ago | 0

| accepted

Answered
how to determine both of sheet number and name of sheet with (writecell)
hello writecell does not allow you to specify in the same command a sheet number and a sheet name Specify the worksheet to w...

25 days ago | 0

Answered
Is it possible to align two data sets with irregular sampling while preserving the respective indices?
hello I gave it a try and this is my best result so far first I simply used the time delat between the red dots (easy soluti...

25 days ago | 0

| accepted

Answered
single sided fast fourier transfrom from a data file
hello if your number of periods recorded is not very high and your signal is "clean" then I would prefer to mesure the time di...

1 month ago | 0

| accepted

Answered
How do I perform a formatted read on exponential data?
Coming a bit too late in the show... filename = 'tabled1.txt' header_lines = 1; data = get_my_data(filename,header_lines) ...

1 month ago | 0

Answered
Second to last row?
hello I have nothing personnally against your code , but it's slow and impractical as you have this issue with the "end" at th...

1 month ago | 0

Answered
Converting beat-by-beat data into second average
hello you can use smoothdata to smooth / average your curve then you do the interpolation to resample at dt = 1 second nota t...

1 month ago | 1

Answered
how to generate multiple curves with the same track length
hello try this % rope at rest (straight) would have length = 1 (= max(t)) n = 1000; t = (0:n-1)./n; max_length = 0.7; %...

1 month ago | 0

| accepted

Answered
How do I import multiple CSV files from a directory as tables in the workspace?
hello try this %% read multiple csv files P = pwd; % currrent directory S = dir(fullfile(P,'*.csv')); % get list of files...

1 month ago | 0

Answered
Help with finding frequency, amplitude and error of a signal that I'm uploading from a simulink model
hello again if your data are "clean" sinewaves but the number of samples is limited then computing the period via the time diff...

1 month ago | 0

| accepted

Answered
How to identify and read similar files names in a folder and then create a matrix array with the data
so an updated version of the code to load data and headers of your files I used an older but still usefull readclm function (se...

1 month ago | 1

| accepted

Answered
How to identify and read similar files names in a folder and then create a matrix array with the data
hello I created first some dummy files according to the list (would have been a bit easier with a txt file rather than a pictu...

1 month ago | 1

Answered
How to plot the time series data after remove the phase lag?
hello I assume this is the result you are looking for for me 170° is almost a polarity inversion, so I changed the y to -y a...

1 month ago | 0

| accepted

Answered
How to find the maximum point of a fitted curve
hello a simple and compact code that only uses this Fex submission smoothn - File Exchange - MATLAB Central (mathworks.com) ...

1 month ago | 0

Answered
using regexp to parse specific line
hello I assumed there could be more than one line , but I also assumed that they would be written exactly the same way so I en...

1 month ago | 0

| accepted

Answered
Data in multiple separate .xlsx sheets and move to only one .xlsx sheet
hello again Augusto try this code : make sure you have downloaded the File Exchange submission first : Natural-Order Filena...

1 month ago | 0

| accepted

Answered
How to store char to a text file?
hello Mark try this ; your char array must be first transformed in string , otherwise this code will not work hope it helps ...

1 month ago | 0

| accepted

Answered
How Can I Plot Multiple Points Without Mathlab Joining Them?
hello as usual , first thing to do is to read the doc 2-D line plot - MATLAB plot - MathWorks France you can get a dotted p...

1 month ago | 1

Answered
Combine excel files into one
so I relicated the same folder tree and file name (same in every folder) this is a slightly modified code , try it : path ...

1 month ago | 0

| accepted

Answered
How can I use smoothing like in excell?
hello try with smoothdata from your data , I was expecting that freq is your x array and material_A your y array this is wha...

1 month ago | 1

| accepted

Answered
formatting text file using matlab
hello let's start with one file ... then we will add the for loop to process many files in one operation there is still one p...

1 month ago | 1

Answered
FFT for Lift coefficient to find the frequency
hello I prefer to put the repetitive fft lines in a subfunction , so the code can be cleaner and more compact for the fft re...

1 month ago | 0

| accepted

Answered
Download NetCDF data via command window
hello (again) Augusto try this code. The results are saved in one single excel file (attached FYI), each year on a new sheet...

1 month ago | 0

| accepted

Answered
While loop stops short of meeting the condition
hello @Milos Krsmanovic why not using this code ? as you see the zero (or any other threshold value) points are obtained with l...

2 months ago | 0

| accepted

Answered
How to put an audio file through a filter made through matlab
hello some corrections needed, but you were pretty close to the solution [y,Fs] = audioread('song.wav'); Fl = 300; Fh = 3...

2 months ago | 0

| accepted

Answered
Extract data from specific latitudes and longitudes in time in NetCDF (.nc) to .csv
hello Augusto I fixed a few minor bugs in the code . Also I noticed from the nc file that the range for longitude data is 0 ...

2 months ago | 0

| accepted

Answered
How to join multiple Excel files of varying lengths
hello try this : fileDir = pwd; % current directory (or specify which one is the working directory) outfile = 'OUT.xlsx'; %...

2 months ago | 0

Answered
How to obtain PSD of time series data using pwelch()
hello if you want the finest frequency resolution, the fft length must be equal to your signal length. You could even virtuall...

2 months ago | 0

Load more