Community Profile

photo

Adam Danz


Last seen: Today

University of Rochester

2,218 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

Contact

Adam Danz's Badges

  • 24 Month Streak
  • Personal Best Downloads Level 4
  • Explorer
  • Ace
  • Thankful Level 3
  • Editor's Pick
  • First Review
  • 5-Star Galaxy Level 5
  • First Submission
  • Revival Level 3
  • Knowledgeable Level 4
  • Solver
  • First Answer

View details...

Contributions in
View by

Answered
How can I make the plot transparent in a gscattter?
Setting transparency of markers with gscatter is not possible as of r2020a. Workarounds You could use scatter() which does s...

9 hours ago | 0

Answered
How to concatenate a row of variable names and a double?
You can concatenate them within a cell array. Based on your question and title, I'm guessing you've got a row of variable names...

1 day ago | 0

Answered
Linking x and y axis zoom in subplot
See linkprop() Link the xlim and ylim properties. Or use or linkaxes() Here's a demo. It uses tiledlayout instead of subpl...

1 day ago | 0

Answered
how to label strings in an array with an ID
See ismember() StringID needs to be a cell array. Then, [~, idx] = ismember(tc,StringID(:,1)); Also see lower() if you want...

1 day ago | 0

| accepted

Answered
Count the number of indices between two indices
If and only if the following rules are met, the solution is very simple. For every "1" there will be a "-1" and for every "-1"...

1 day ago | 0

| accepted

Answered
Difference between %d and %f?
Refer to the documentation. %d represents signed integers (base 10). sprintf('John is %d years old', 7) % 'John is 7 year...

1 day ago | 0

| accepted

Answered
Calculating mean and SD of histogram
Guessing that column 1 of the data are x-values to the bar plot and column 2 of the data are the bar heights, you can fit a guas...

2 days ago | 0

Answered
Drawing a rectangle over existing plot
To use an annotation object in the way you're describing, you'd need to convert the data units, which are relative to the axes, ...

4 days ago | 0

| accepted

Answered
Two x-axis for the same contourf plot
Matab does not currently offer a second x axis. You can create two duplicate axes and place the x-ticks of the bottom axis on ...

5 days ago | 0

| accepted

Answered
String scalar or character vector must have valid interpreter syntax
You probably want something like title(sprintf('%.2f + %.2f', Rs(1), Ry(1))) See sprintf for more info. Update Set interpre...

5 days ago | 0

| accepted

Answered
calculation time in for loop
If the computations done within the loops are nearly uniform in their complexity, then it's expected that the speed of each loop...

5 days ago | 0

| accepted

Answered
Error using fprintf Invalid file identifier. Use fopen to generate a valid file indetifier
My guess is that Total_Time_t2_64Mb is equal to NaN which would result in s2 = "TOTAL FRAMES SENT = " + NaN +...

5 days ago | 0

| accepted

Answered
Labels to a stacked bar
Here's a demo. % Create stacked bar plot x = randi(3,20,5); h = bar(x,'stacked'); % Get the (x,y) coordinates for the t...

5 days ago | 0

| accepted

Answered
Unnecessary rounding when reading an xlsx
Thanks for providing the raw data. I'm not seeing what you're seeing. My data exporation steps are below. % Read-in the da...

6 days ago | 0

| accepted

Answered
Finding handles to ROI objects such as drawline
h = findobj(axhl, 'type', 'images.roi.line'); The object created by drawline is different from regular line objects. But the...

6 days ago | 0

| accepted

Answered
Index in position 1 exceeds array bounds (must not exceed 46)
The value of n iterates from 1 to 617. The size of D is 46x16. When n=47, you get the error because D(47,:) doesn't exist. ...

7 days ago | 0

Answered
Error in callback function execution in App Designer when called programmatically
As of r2020a, the typical ToolBar is not (yet?) supported for UIFigures (eg, apps) but the property exists which usually means t...

7 days ago | 0

| accepted

Answered
Shift Map in App Designer
Since the worldmap function does not currently support setting parent axes, you'll have to create the plot in an external figure...

7 days ago | 0

| accepted

Answered
App Designer: Subplots in uiplane
Since this isn't your code, I don't have to worry about sounding insulting when I say that this code is a mess! :) I wouldn't ...

7 days ago | 0

| accepted

Answered
Custom Colors for Stacked Bar Chart
Set the FaceColor property to Flat and then define the colormap which specifies the color for each segment. Here are two demos...

7 days ago | 0

Answered
How to close an uialert programmatically
The uialert window cannot be programmatically closed, at least not in r2020a. You can, however, make the uialert non-modal whic...

7 days ago | 0

| accepted

Answered
extract data from structure into table with multiple columns instead of one column
Change T2 = [T2; ICA_selected] % ^ vertical concatenation to T2 = [T2, ICA_selected]; % ^ horizontal concatena...

7 days ago | 0

| accepted

Answered
how can I increase the patch animation speed?
In addition to Star Strider's advice to use getframe, check out drawnow limitrate which will limit the number of times drawnow i...

7 days ago | 0

Answered
Variable X-Tick Labeling
The cleanest solution IMO is to convert your datetime values to the fiscal year values and use the fiscal year values to plot yo...

7 days ago | 0

| accepted

Answered
Multiple X axis in different scale, but one y axis
Matlab does not support mutliple x axes other than the axes at the upper and lower borders of the plot. One way to include mu...

7 days ago | 1

| accepted

Answered
Change the color of each group in boxplotGroup
"Is it possible to have both a in each group green; and have both b in each group yellow?" Yes. Use the "colors" propery but i...

8 days ago | 1

| accepted

Answered
Making a contour plot from x and y data
The bivariate density can be computed using histcounts2. You'll need to specify either the number of bins or the bin edges for ...

13 days ago | 0

| accepted

Answered
Checking the dates and times
Why not use a UI such as https://www.mathworks.com/help/finance/uicalendar-graphical-user-interface.html https://www.mathwork...

14 days ago | 0

| accepted

Answered
Overlay plot of UIAxes
You can plot the line using xline() and then merely update it's Value property to move it. The line's handle must be stored as a...

14 days ago | 1

| accepted

Answered
Text beside the pointer in ginput
No can do. The ginput function suspends all interactive properties of a figure window so even if a WindowsButtonMotionFcn func...

15 days ago | 1

| accepted

Load more