Community Profile

photo

Star Strider


11,442 total contributions since 2012

Hic sunt dracones!

PROFESSIONAL: Physician (M.D.): Diplomate of the American Board of Internal Medicine; M.Sc. Biomedical Engineering: Instrumentation, Signal Processing, Control, System Identification, Parameter Estimation

NON-PROFESSIONAL: Amateur Extra Class Amateur Radio Operator; Private Pilot, Airplane Single Engine Land, Instrument Rating Airplane; Gamer

NOTE: I do not respond to emails or personal messages, unless they are about my File Exchange contributions.

Contact

Star Strider's Badges

  • Grand Master
  • 36 Month Streak
  • Thankful Level 3
  • Revival Level 2
  • Knowledgeable Level 4
  • First Answer
  • Scavenger Finisher
  • Solver

View details...

Contributions in
View by

Answered
How do I adjust my histogram to show approx. 50 different categorized bins with very small data?
You need to subscript ‘t’ to save it as a vector. Try this: iter=10000; FS=40; for n=1:iter Sy=2.11*10^8+(60*rand(1)...

8 hours ago | 0

| accepted

Answered
Using the 'Surf' command for variable 'x' values
It doesn’t work because ‘y’ is a vector. Try this: x= [1.158633 4.871195 7.667851 11.45038 22.11895 1.221922 3.77...

11 hours ago | 0

| accepted

Answered
Adding standard error bars to grouped bar graph
You are in luck in not using categorical variables, because this approach will not work with them (although I’ve not had the opp...

14 hours ago | 0

Answered
Find next value above threshold
The find (link) command may be what you want. It will return the index of the value, so you can then use that index to get the ...

15 hours ago | 0

Answered
Need to combine every other column of two row vectors of different sizes in MATLAB
One approach: A = [1 3 5 7 9 11 13 15 17]; B = [2 4 6 8 10 12]; C(1:2:numel(A)*2) = A; C(2:2:numel(B)*2) = B; C = C(1:mi...

17 hours ago | 1

| accepted

Answered
How do I multiply a column in a matrix by a range of values?
I am not at all certain what result you want. Try these: spark_rng = linspace(-12, 30, numel(sfd(:,3))); ...

24 hours ago | 0

Answered
How to order variables by their size?
Try this: [~,ix] = sort(cellfun(@sum, onsets)); Out = names(ix) producing: Out = 1×3 cell array {["C"]} {["...

1 day ago | 1

| accepted

Answered
how to extract pcg signal features from a dataset for machine learning
See Wavelet Time Scattering Classification of Phonocardiogram Data (link).

1 day ago | 0

| accepted

Answered
low pass filter to matrix
You can apply any filter to a matrix using the filtfilt (link) function to do the actual filtering. From the documentation: ...

1 day ago | 0

Answered
How to locate last peak in data?
Use the findpeaks (link) function, most likely with the 'MinPeakHeight' name-value pair. Then use the second ‘locs’ output (an ...

1 day ago | 0

Answered
3D spectrum plot with massive data sets
The spectrogram (link) function will likely do what you want.

1 day ago | 0

Answered
Sample a continuous signal with Sampling frequency
‘Would I do this by only looking at the points of the signal that correspond to the sampling frequency I decide on?’ Yes. In...

2 days ago | 0

Answered
Syntax Question struct array - Unexpected MATLAB operator.
Refer to general arguments in your function definition, not specific variables. So your function would be defined as: funct...

2 days ago | 0

| accepted

Answered
changing diagional values with different values
I am not certain what result you want. Try this: MX1 = randi(9, 4) D1 = diag(MX1); Xv = sum(MX1,2) - D1; MX1 = triu(MX1,...

2 days ago | 1

| accepted

Answered
Inserting Timestamp into a Matrix
I still have no idea what you want to do. However, if you want to concatenate the even rows to the odd rows and have ‘2019’ b...

2 days ago | 0

Answered
integrate 2D data
Use trapz (link) or cumtrapz (linked to in that page).

2 days ago | 0

Answered
Taking second derivative and solving it for when it equals 0
I am not certain what you are doing. Taking the derivative of data will significantly amplify any noise that might be present, ...

2 days ago | 0

| accepted

Answered
reassigning a value in a piecewise function
I am not exactly certain what you want to do. Try this: syms y(x) y(x) = piecewise(0<=x<25, 0,25<=x<=50, 0.5+x/50, 50<=x<=...

2 days ago | 0

Answered
How can i store values calculated in my loop
I am not certain what you are doing. One option is to create a second matrix (‘X2’ here), and store the results in it: X = [9...

3 days ago | 1

| accepted

Answered
How do i know the limits for maxfunevals and tolx?
You can set them to be whatever you like (within limits). If you want to know the default values, use an optimoptions (link) ca...

3 days ago | 1

Answered
Finding closest point to known coordinates
The minimum distance of a set of points is the Centroid (link), defined as the mean of the coordinates of the points: xy = [1 ...

3 days ago | 0

| accepted

Answered
How to sum data points within contour lines/isolines?
You can certainly get the (x,y) coordinates of the contours, although it takes a bit of code the get the result you likely want....

3 days ago | 0

Answered
Scattering 3D points (x y z) on a 2D plot (x y)
Use the scatter3 (link) function, and the view (link) function, specifically: view(0, 90)

3 days ago | 0

| accepted

Answered
Creating function for baseline correction
If you want to understand how to write MATLAB functions, see: Function Basics (link).

3 days ago | 1

| accepted

Answered
anyway to compare date in Matlab
It might be easier to use the datenum field instead if you simply want to compare dates: filenames1=dir'(D:/test/); time_file...

3 days ago | 0

Answered
plotting an N segments circle
WHY? Because you are plotting a decagon rather than a circle. If you want them to be on the line, you need to reduce their rad...

3 days ago | 1

| accepted

Answered
Inputting a certain number of data points between two values
x = linspace(0, pi, 10);

3 days ago | 0

| accepted

Answered
Error using < Matrix dimensions must agree.
You apparently have R2016a or earlier, so you do not have ‘automatic implicit expansion’ that was part of R2016b and later versi...

4 days ago | 0

| accepted

Answered
How do I name the trendline in the legend? Also, how can I get the trend line equation on the plot?
It is not possible to run an image of your code. Try this: Voltage = linspace(10.45, -1.4, 8); GaugePressure = linspace(33...

4 days ago | 0

Answered
Resampling a matrix of data to increase data sample rate
Use the Signal Processing Toolbox resample (link) function. It is specifically designed for signal resampling, and includes an ...

4 days ago | 0

| accepted

Load more