Community Profile

photo

Walter Roberson


42.243 total contributions since 2011

I do not do free private consulting. If you want to bring my attention to something, send a link to the MATLAB Answers location.

Contact

Walter Roberson's Badges

  • Most Accepted 2018
  • Most Accepted 2017
  • 36 Month Streak
  • Most Accepted 2016
  • Most Accepted 2015
  • Most Accepted 2011
  • Most Accepted 2012
  • Most Accepted 2013
  • Thankful Level 4
  • Grand Master
  • Revival Level 4
  • Knowledgeable Level 4
  • First Answer
  • Solver

View details...

Contributions in
View by

Answered
How to prevent conv2d from changing image size
conv2(A, B, 'same') or conv2(A, B, 'valid')

etwa 5 Stunden ago | 0

| accepted

Answered
Adding new field to structure array
Not really. You could reduce by one line by using a = num2cell(arrayfun(fun, [s.f1], [s.f2])); for whatever that is worth. Yo...

etwa 7 Stunden ago | 0

Answered
Installing Matlab in a pen-drive
Often pen drives mount in Linux with the no execute option. Also it is not uncommon to need to sudo sh ./install My understa...

etwa 8 Stunden ago | 0

Answered
Which version can support the naming of m files in Chinese and the use of space naming?
On all versions, function names (and the last component of the names of .m files) can only use A-Z, a-z, 0-9, and underscore. I...

etwa 8 Stunden ago | 0

| accepted

Answered
Cannot find a license for distrib_computing_toolbox
Your session is configured so that your default parallel pool is on a remote system, but you do not have (an available) license ...

etwa 9 Stunden ago | 0

Answered
Using fprintf to output %e with one decimal point
You cannot get two digits before the decimal place in a %e format. You also cannot skip the sign after the E. Also, for large en...

etwa 10 Stunden ago | 0

Answered
how to know if image is rgb?
For some kinds of image files, it is not possible to be sure. You can try using imfinfo() on the image file, and looking for th...

etwa 11 Stunden ago | 0

Answered
How to skip the division of zero in three summation term.
syms n M N F = n-M-N; Fz = piecewise(F == 0, 0, 1/F); T = symsum( symsum( symsum( Fz, n, 1, 3), M, 1, 3), N, 1, 3)

etwa 11 Stunden ago | 0

| accepted

Answered
How to save matrix to .dat file in standard notation
You cannot do that using save -ascii: save -ascii uses a fixed format. Probably the easest way is filename = sprintf('output=%...

etwa 12 Stunden ago | 0

| accepted

Answered
I need help building a dynamically evolving matrix based on a polynomial of unknown or user inputted size.
xv = x(:); yv = y(:); X = []; deg = 0; while true X = [X, xv.^deg]; coeffs = X \ yv; residue = sum( (polyval(...

etwa 13 Stunden ago | 0

Answered
range2time is not working?
range2time requires the Phased Array Toolbox, R2012b or later.

etwa 15 Stunden ago | 0

| accepted

Answered
how can I output an option from menu after the user has selected an option
materials = {'ash', 'hicory', 'maple', 'pine'}); BatMa = menu('choose the bat material', materials); if BatMa == 0; error('can...

etwa 15 Stunden ago | 0

Answered
Can any one help me on this
Code is attached. I had to guess about what you were trying to do. One of your cases leaves m undefined. That case occurs for y...

etwa 15 Stunden ago | 0

Answered
Code for laser ablation of material
Something like initialize mass initialize velocity while velocity < target decrease mass increase velocity by force...

etwa 16 Stunden ago | 0

Answered
Adding Zeros vectors within a matrix
A2 = zeros(5,5); A2([1:2, 5], [1:2, 5]) = A;

etwa 17 Stunden ago | 2

| accepted

Answered
who to make code in gui work in any image the user input?
Same cause as for your slightly earlier and very similar posting. https://www.mathworks.com/matlabcentral/answers/457700-i-hav...

etwa 18 Stunden ago | 0

Answered
i have code in gui and if condition does's work why? please help me
radial basis networks are function approximations, and will seldom return exact integers -- especially since we do not know that...

etwa 18 Stunden ago | 0

Answered
plotting help needed (increasing resolution)
Increase N, so that more t values are used.

etwa 20 Stunden ago | 1

| accepted

Answered
what is the difference between rgb2gray and im2bw ?
No, rgb2gray() converts to grayscale. For uint8 images, the output could have up to 256 unique values in the matrix. im2bw() con...

etwa 20 Stunden ago | 0

| accepted

Answered
inserting image in a table
With traditional figures (**not** App Designer), you create a uitable. The column that is going to contain the images has to be ...

etwa 20 Stunden ago | 0

Answered
How to randomly choose 5% of a matrix to be of value 1.
candidates = find(~YourMatrix); ncand = length(candidates); locs = randperm( ncand, round(ncand * 0.20) ); YourMatrix(locs) =...

etwa 21 Stunden ago | 0

| accepted

Answered
Is there a way to add constraints (other than nonnegativity) on ode15s?
Only in the sense that you could add an event function to detect the value going out of range, and terminating when it does. If ...

etwa 23 Stunden ago | 0

| accepted

Answered
Fsurf plot wrong when x coefficient is 0
When you construct an expression A*x + B*y + C with symbolic x and Y, and A is 0, then the symbolic engine does not deliberately...

etwa 23 Stunden ago | 0

Answered
How to extract data from Cell?
cellfun(@(M) M(1,ColumnToSelect), a(RowsToSelect)) Or in the special case of the cell containing row vector of the same lengt...

etwa 23 Stunden ago | 0

| accepted

Answered
How to use polyfit to get the difference out of two functions?
P1 = polyfit((1:length(X)).', X(:), 6); Likewise for Y producing P2 Pd = polyval(P1, 1:length(X)) - polyval(P2, 1:length(X...

ein Tag ago | 1

| accepted

Answered
Plotting 2d data
t = 0.003 is a scalar, but you index t(i) Caution: your i and j are scalars, so plot(j, q(i,j), 'b-') is going to try to plot a...

ein Tag ago | 1

| accepted

Answered
get RGB data from image
Your search encounters a pixel with components 5 6 255 . Your test for assigning a new brightness requires that **all* of the r ...

ein Tag ago | 0

| accepted

Answered
different font sizes for y labels
set(gca, 'fontsize', 16) %the larger of the font sizes set(gca, 'YTickLabels', {'\fontsize{12}{-4}', '-2', '\fontsize{12}{0}'...

ein Tag ago | 0

| accepted

Answered
How can I present a 3D particle with cube mesh?
Use patch() with 'Faces' and 'Vertices' . I gave an example for a cuboid at https://www.mathworks.com/matlabcentral/answers/4441...

ein Tag ago | 0

Answered
Find specific cell in another cells
match = {21 31 1} does not exist in your actual condition variable. Your actual condition is a cell array of cell arrays of cha...

ein Tag ago | 1

| accepted

Load more