Community Profile

University of Rochester

2.666 total contributions since 2014

Email: feel free to contact me regarding my shared files on the file exchange. I don't do free consulting outside of the forum so if you have a Matlab question, post the question to the forum and you may email me the link to the question.

About me: Finishing PhD soon on topics related to vision science; neurophysiology; sensory-motor feedback and control; control systems; steering & navigation; multisensory integration; top-down bottom-up feedback loop.

"If I had only one hour to save the world, I would spend fifty-five minutes defining the problem, and only five minutes finding the solution." -Albert Einstein

"An expert is a person who has made all the mistakes that can be made in a very narrow field." -Niels Bohr

"If you are not embarrassed by the first version of your product, you've launched too late" - Reid Hoffman

View details...

Contributions in
View by

How to normalize a discrete signal?
Audio data are typically already normalized between [-1,1]. Are you getting values outside of that range? min(y) max(y) Anyw...

circa 2 ore ago | 0

Subtracting XYZ coordinates defined by matrices
I think what you're asking is how to remove rows of A that are nearly equal to rows of B. Removal is different from subtraction...

circa 2 ore ago | 0

Writing the built in matlab function in simple code(like for loop, etc.)
You can use implicit expansion which is supported in Matlab r2016b and later (more info). y=[1 2 3 4]; OccurancesParameter= 5...

circa 3 ore ago | 0

How can I find the max value and location within a matrix
[maxval, idx] = max(M);

circa 4 ore ago | 1

Find ascii numbers from cells
Matlab stores characters as Unicode characters which incorporates the ASCII character set as the first 128 sumbols. Convert c...

circa 4 ore ago | 0

Plotting a smooth curve from points
You could add values to the beginning and end to make the curve continuing in both directions. The example below uses hard-coded...

circa 4 ore ago | 2

How to formulate elegantly and performant functions that depend on a lot of input variables
A set of inputs like the example you shared is not inelegent. Some may argue that it's more elegant than the alternatives. Wha...

circa 4 ore ago | 0

how do correct the error in this line? print is nor recognised
"Print" is not a name-value option for that function. I think you're looking for, X1fit = estimate(modelX, Xest(:,1),'Display...

circa 5 ore ago | 0

| accepted

Size issue in Matlab App Designer
Set the UIFigure's AutoResizeChildren property to off (in-check the checkbox). If you want more flexibility over how your app a...

circa 5 ore ago | 0

How do I replace elements of an array with letters?
Sounds like you're describing this, number_cycles = 10; labels_I03 = categorical(repmat({'N'},1,number_cycles)); abnormal_cy...

circa 5 ore ago | 0

Manipulate amplitude without using linspace
Since square returns values in the range of [-1,1], rescaling to [-2,1] is as easy as multiplying by 1.5 and subtracting 0.5 whi...

circa 6 ore ago | 1

setting axis ticks on heatmap
If you want to change the tick labels, h = heatmap(__); h.XDisplayLabels = % string array or cell array of character vectors ...

1 giorno ago | 0

| accepted

Submitted

Draw randomly centered circles of various sizes
Set the range of radii, density, and other parameters to create a plot that draws randomly centered polygons with or without ove...

generating random , non uniform fiber distribution of circle in square
Using bubblebath() from the file exchange (see another demo here), figure('Color','w') ax = axes(); axis off S.axisHandle...

3 giorni ago | 0

Remove duplicate rows in table
Follow the demo. T is a table T.Test contains the test names which can be strings, character vectors, categoricals, or numeric...

3 giorni ago | 0

| accepted

Why is one of my tiled plots not being displayed? MATLAB UI App Designer
plot(ax4,theta(1:length(theta)-3),jerk,'c') % ^^^ you forgot this part

3 giorni ago | 1

| accepted

How do I measure density of random point with a fixed area in MATLAB?
Use histogram2() or histcounts2() to compute 2D density. Demo: xy = randi(400,50,2); subplot(1,2,1) plot(xy(:,1), xy(:,2),...

3 giorni ago | 1

| accepted

Creating matric of multiple arrays
Perhaps this (scroll down to see vectorized version)? x=0:12; k=5; a=k+x; b=k+2*x; c=k+4*x; d=k*x; Z = nan(2,2,numel(...

3 giorni ago | 1

Butterworth filter design calls bilinear and fails
You likely had another file on your Matlab path with the same name as butter. If the error happens again, the following command...

3 giorni ago | 1

| accepted

Generate a geographical heat map
I think this is what you're looking for. heatmap Note the change in inputs from matrix to vector of unique values. rng('def...

3 giorni ago | 0

| accepted

creating one output and 2 inputs function in script file
> Write a function in a scirpt file that has two inputs: a scalar z and the matrix M, hence y =f(z,M) Hint: z is not scalar in ...

3 giorni ago | 0

| accepted

Delete rows in a table where data in one column is below a value
> I want to delet all rows where the value of the data in the 4th columns is less than 0.1. T(T{:,4}<0.1,:) = [];

3 giorni ago | 0

| accepted

Replace elements in array
I wouldn't call this an algorithm. It's just indexing. If something more robust is needed we'll need a more detailed descripti...

3 giorni ago | 0

| accepted

How can I compare a datetime array with a timetable to delete all not existing days in it?
To match dates while ignoring time, use ismember() along with dateshift() to ignore time. Demo: TT is a timetable with dat...

3 giorni ago | 1

| accepted

Conditionals in Matlab app.designer?
Avoid using "==" to test equaltify for non-numeric and non-scalar values. For strings / character arrays, use, if strcmp(ap...

3 giorni ago | 0

| accepted

Extract the column/ row numbers or adress
> I would like to get the information on column numbers which got the value 1 For logical row vectors or numeric row vectors c...

3 giorni ago | 0

| accepted

error converting chars to string
Assuming Samples is a cell array Samples{m} = convertCharsToStrings(regexprep(Name, '\s+', '')); % ^ ^ If Samples isn't...

3 giorni ago | 0

| accepted

How do I use fitgmdist with a set of data that is not in a histogram format
You could fit the distribution to a tri-modal mixture of gaussians but very little data and a very narrow peaks (1-2 bars), you'...

4 giorni ago | 0

| accepted

How can I create three different subplots of a patch model, with different camera views?
Create the first subplot using subplot or tiledLayout. Plot your patch object(s) and set up the subplot to its final appearance...

5 giorni ago | 0