Community Profile

Anthony Hopf


UMass Amherst

62 total contributions since 2010

Contact

Contributions in
View by

Posted


Randperm, Randi, and Shuffle
I am trying to replace the following code: [rix riy riz] = ind2sub(sampbox,randi(myrandistr,prod(sampbox),SPtemp,1)); where sa...

6 years ago | 10562 views

Responded


Re: Multiline suplabel with latex
Saw this in the FEX comments by Lars: Quite useful and simple to use. You might consider to change the argument checking to all...

6 years ago | 2438 views

Posted


Multiline suplabel with latex
I can't seem to get this to work. I have a combination of variables and latex in a title I would like to put over several subpl...

6 years ago | 2438 views

Responded


Re: matlab solve function
I screwed up the code: npa = 1.3; bwaz = 2; az1 = 0; gamma = az1+(bwaz/cosd(az1)^npa)/2; solve('az2 - (bwaz/cosd(az2)^npa)/...

6 years ago | 10596 views

Posted


matlab solve function
here is the code: npa = 1.3; bwaz = 2; az1 = 0; gamma = az1+(bwaz*cosd(az1)^npa)/2; solve('az2 - (bwaz*cosd(az2)^npa)/2 - ga...

6 years ago | 10596 views

Responded


Re: Summing 2 Cell Arrays
Kinor Thank you very much for the reply. I've never played with this syntax, cellfun or arrayfun. T

6 years ago | 1657 views

Posted


Summing 2 Cell Arrays
I hope this is a simple question to answer. But I have a cell array NxK made up of Mx1 vectors of varying length. I would like...

6 years ago | 1657 views

Responded


Re: Using Find within "sub-array"
Actually, while this is a nice process, is there any way to just modify idx without having to create the SubMx? I can see how t...

6 years ago | 5181 views

Responded


Re: Using Find within "sub-array"
Matt, this is essentially what "find" does right? the example I gave above was simplified too... I am doing a 3 dimension logi...

6 years ago | 5181 views

Posted


Using Find within "sub-array"
Here is the issue I am having. I have an mxn matrix, that is very large. I would like to use the find command but it is pretty...

6 years ago | 5181 views

Responded


Re: Index matrix to sparse matrix... saving memory
Bruno, Is there any reason that I would get different values for the output of histcn max(loc) and size(count)? I have not had...

6 years ago | 13150 views

Posted


Removing rows containing all zeros in a matrix
But what if you want to replace the values? m(any(m ==0,2),:)=[1 1 1]; This doesn't work, I get a dimension mismatch problem. ...

6 years ago | 63609 views

Posted


Removing rows containing all zeros in a matrix
us, very cool. If you want to get rid of any row that has 0's in it m = m =

6 years ago | 63609 views

Responded


Re: Raytracing for a 3-D structure
Any luck with this? Seems like something that is done all the time in video games... I'm kind of surprised something similar ha...

6 years ago | 3542 views

Responded


Re: Index matrix to sparse matrix... saving memory
Thank you Bruno... The extreme speed up I see using accumarray may negate the need to bin all of the index values for storage. ...

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
Thank you very much Bruno, and others, for giving your advise... I had all of the resources to accomplish number 2... haven't ...

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
Bruno... I can't believe I missed the funcitonality of histcn and accumarray!! This definitely gets me closer to my ultimate re...

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
I understood, and appreciate your help. accumarray it is!! I'll post my solution when I figure this function out. Anthony

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
Bruno or anyone that has looked through the thread, I'm beating myself up here... I just can't see through to the end. Histcn ...

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
I feel like I am sooo close.... My issue is with finding the intersection between 3 sparse logical matrices idxr, idxa, and id...

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
So I think a couple lines fixed the problem: %%%%%% bin_size = 100; r_bin_max = ceil((((nanmax(double(r_4d(:))))))/bin_size); r...

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
Thank you Matt and Bruno!! I apologize for not staying with this topic, but I have quite a bit on my plate... and I am taking y...

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
Thank you for your help, I apologize for my slow learning... you guys really are very good! Anthony

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
Sorry to "double" post this (seems to fit here much better than the other thread)... but I think I am starting to see the light ...

6 years ago | 13150 views

Responded


Re: Set interestions/Searching in large Matrices
Here is the exact code I am using. My output is a sparse matrix (to conserve memory... there are many zeros... I use ~10% of th...

6 years ago | 2505 views

Responded


Re: Set interestions/Searching in large Matrices
Bruno, I hate to rehash this, but the code I am using now is inefficient (and you mentioned that this would be a more effective...

6 years ago | 2505 views

Responded


Re: Index matrix to sparse matrix... saving memory
Bruno, I think you are right on with your statement "It seems you are trying to visualize what HISTN does in term of geometry, ...

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
Bruno, I had downloaded your histcn function at one point to try and understand how it could be applied to my problem, but I mu...

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
I have two questions concerning the above and something else that goes to the above 1. I am curious about the best way to build...

6 years ago | 13150 views

Responded


Re: Index matrix to sparse matrix... saving memory
Matt, that is a very good point. but I use the index values to pick out points in a 3d xyz data structure, add them and replace ...

6 years ago | 13150 views

Load more