Answered
Is there a way to fit experimental data to a set of x,y points?
Hankel functions are new to me, so I looked this up. Wolfram MathWorld a has a description: ...

3 years ago | 0

| accepted

Answered
How do I access sub-columns in table
Try this — I = [1 2 3; 1 2 3;1 2 3]; J = [4 5 6;4 5 6;4 5 6]; K = table(I,J) VN = K.Properties.VariableNames; I1 = table...

3 years ago | 0

Answered
plot3 command error in dlode45
The problem is that ‘y’ is a dlarray (the first time I’ve encountered one so I need to start working with the Deep Learning Tool...

3 years ago | 1

| accepted

Answered
converting indices into time
Try this — F = openfig('figure1.fig'); Lines = findobj(F, 'Type','line'); tidx = Lines.XData; speed = Lines.YData; Fs = 3E...

3 years ago | 0

| accepted

Answered
How to save user input as variable I can compare?
The ‘data’ values are geing read correctly, however the second ‘data’ assignment is overwriting the first one. Perhaps: da...

3 years ago | 0

| accepted

Answered
Can I use ismembertol to find x,y coordinates that are close to each other?
The best approach to find (x,y) pairs that are close to each other is probably to use pdist2. You can then compare the distance...

3 years ago | 0

Answered
Problem in plotting the convolution
Use the 'same' argument so that the output is the same size as the input: yt= conv(xt , ht, 'same'); This works — dt= 0.000...

3 years ago | 0

| accepted

Answered
Problem adding labels to figure
One problem is that just after creating the figure the code clears it. Otherwise perhaps something like this — fig=figure(3...

3 years ago | 1

| accepted

Answered
How can i plot sections of a horizontal line?
One approach — t = linspace(0, 15, 150); v = ones(size(t)); G{1} = (t >=3 & t<=4); G{2} = (t>=14 & t<=15); K{3} = (t>=7 & ...

3 years ago | 1

| accepted

Answered
Directed transfer function (DTF) calculation for EEG data
The Wikipedia article on Brain connectivity estimators provides a llink to HERMES that apparently can be downloaded (I have no r...

3 years ago | 0

Answered
add text to the axis
Perhaps this — t = 0:24; y = rand(3,25); figure plot(t, y) grid text([13 6 18], zeros(1,3), {'noon','sunrise','sunset'}...

3 years ago | 0

| accepted

Answered
Error with ode45 in line 89. Trying to use ode 45 to give data on a 4x4 state space matrix
I am not exactly certain what you want to do. This is my best effort to make sense of it — x1_0=1; v1_0=1; x2_0=0; v2_...

3 years ago | 0

Answered
Extract plot statistics for a specific range
I don’t have the Curve Fitting Toolbox, however looking at the documentation for the datastats function, one option would be: ...

3 years ago | 1

Answered
Why do I get the error "Subscript indices must either be real positive integers or logicals." ?
Wioth the additional multiplicationo operators in ‘dYdx(6)’ and ‘dYdx(8)’ it appears to run without error — %define space f...

3 years ago | 0

Answered
Convert cell array to filename
See: Access Data in Cell Array

3 years ago | 0

Answered
update the column headng by readin the excel file
If you want the variable names, first: T1 = readtable('YourFile.xlsx', 'VariableNamingRule','preserve') then: ColumnHeading...

3 years ago | 0

| accepted

Answered
I want to shade the upper region of the four curves and left region of the vertical line
Try something like this — x=0:140; M=(9.88./x)+((0.00044)*x); T=(0.04-(0.0516*(exp(7.442./(x)))))./(1-(exp(7.442./(x)))); R...

3 years ago | 0

| accepted

Answered
Is there a way to use findgroups() so that it is based on order in the matrix instead of alphabetical?
There doesn’t appear to be that option for findgroups. If you only have one vector, the unique function can do thaat using the ...

3 years ago | 1

| accepted

Answered
calculating the difference in dates
Try something like this — T1 = readtable('dates.xlsx', 'VariableNamingRule','preserve') YearMonth = datetime(T1{:,1},T1{:,2},...

3 years ago | 1

| accepted

Answered
Derivative spectra from table, but error appears: Arrays have incompatible sizes for this operation
Use the gradient function instead: dydx = gradient(y,1)./gradient(x,1); The outputs are the same sizes as the arguments. ....

3 years ago | 0

| accepted

Answered
How do I create a 3D plot using the messgrid command from data within an Excel file?
The meshgrid call is actually not necessary. Try this — T1 = readtable('Epsilon_Prime.xlsx') T1.Var2 = str2double(T1.Var2)...

3 years ago | 0

Answered
how convert field struct in cellarray
See if the struct2cell function will do what you want.

3 years ago | 0

| accepted

Answered
How can i read a .isf file?
See this post on the Tektronix site. It tells how to save the file as a .csv file. After that, use readtable or readmatrix to ...

3 years ago | 0

Answered
How to plot contour lines on MATLAB?
See if contourm will do what you want. (I do not have the Mapping Toolbox since I do not need it for what I do, so I have no ex...

3 years ago | 0

Answered
accelerometer data shows nothing in FFT
Perhaps something like this — data = readmatrix('usb_data_100hz2.17th.txt'); x = data(:,1); y = data(:,2); xstats = [mean...

3 years ago | 0

Answered
Ussing input to read an excel file
There are several options. Without having the file to work with, readtable and readcell could be appropriate. The xlsread fu...

3 years ago | 0

Answered
Need to load a file from an open data set a
Perhaps something like this: file = "C:\Users\Joyfu\Downloads\SOCR-HeightWeight.csv"; A = readmatrix(file) Col1 = A(:,1); ...

3 years ago | 0

| accepted

Answered
Locate values in a matrix
A reasonably general approach would be to use the Signal Processing Toolbox sgolayfilt function to smooth the data (there are oi...

3 years ago | 1

Answered
Peak area through Findpeak
It depends on how you define ‘peak’. LD1 = load('X4.mat'); X4 = LD1.X4; LD2 = load('Y20_4.mat'); Y20_4 = LD2.Y20_4; [pk...

3 years ago | 0

| accepted

Answered
How do I generate numbers from an Exponential Distribution within Min and Max values?
Use the truncate function — pd = makedist('Exponential','mu', 1.5); t = truncate(pd, 0.5, 4.3); r = random(t,10000,1); ...

3 years ago | 1

| accepted

Load more