how can i understand this code about breast cancer detection? here I'm giving only small part of the cede, i want line by line explanation.
2 views (last 30 days)
Show older comments
butterfly .
on 17 Feb 2017
Commented: Walter Roberson
on 17 Feb 2017
gui_Singleton = 1;
gui_State = struct('gui_Name', mfilename, ...
'gui_Singleton', gui_Singleton, ...
'gui_OpeningFcn', @BrestCancerDetection_OpeningFcn, ...
'gui_OutputFcn', @BrestCancerDetection_OutputFcn, ...
'gui_LayoutFcn', [] , ...
'gui_Callback', []);
if nargin && ischar(varargin{1})
gui_State.gui_Callback = str2func(varargin{1});
end
if nargout
[varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
gui_mainfcn(gui_State, varargin{:});
end
0 Comments
Accepted Answer
Walter Roberson
on 17 Feb 2017
I could probably write more than 20 pages of "line by line explanation" of that code. Which would be a very time consuming thing for me to do, and I am not going to do it. I have no idea what your level of experience with computer programming or MATLAB is, so I would have to assume that you have never seen a computer program before, and write a small book about the concepts so that I could be sure you understood the significant of the explanation of those lines.
You need to ask specific questions. Why do you care what it does? It is Magic GUIDE Initialization Code for a GUI named 'BrestCancerDetection' . As long as you keep using GUIDE, GUIDE will automatically update it as needed.
The code you posted has nothing at all to do with how the program actually detects cancer: it is code that has to do with making the point-and-click interface work properly.
More Answers (1)
Image Analyst
on 17 Feb 2017
Ignore it. It's just boilerplate GUIDE code that's at the top of every GUIDE-generated m-file. Trust me, no one cares about that stuff. No one bothers to try to understand it - we've got better things to worry about. It's just inserted there by GUIDE and it can be ignored. Really. It's like saying you can't drive your car unless you know and understand every page of the auto mechanics service manual for it. Not necessary. Don't waste your time. What's more important is the code that is in the OpeningFcn() function and the callback functions.
3 Comments
Image Analyst
on 17 Feb 2017
Possibly, if it's just about a short section. I'm not going to go line by line through a thousand lines of uncommented code with cryptic sounding variable names and explain them all. Why don't you ask the actual author of the code to help you understand it?
Walter Roberson
on 17 Feb 2017
I understand the posted code, which is why I can say that is not worth spending time on unless there is a specific question to be answered about it.
See Also
Categories
Find more on Genomics and Next Generation Sequencing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!