If you aren't required to do it in a particular format, I'd recommend publishing the code online and using a nice LaTeX code formatting package for the parts you want to share in the print version. My personal favorite is . Very easy to use, beautiful formatting and coloring and no need to copy and paste anything, just use the command.
Yes, your code should be in the appendix, monospaced, single column. You do not have to turn in all code used in your experiment; use your best judgement. You may want to include only relevent sections of code. For example, you should not include code that someone else wrote, unless you made major modifications. If your code is 100 pages, you should not print all of it. If your code is 6 pages, then you should print all of it.
When I read code, while I'd want it to be a typical font size (12 pt), I'd also want the text-wrapping to be minimal, but given the traditional margin requirements, it can be pretty tough to accomplish this. Having code trail off one line and onto the next is generally distracting.
There are a number of excellent LaTeX packages for typesetting code, made for just such occasions. The is one good example, which includes standardized formatting for a number of languages.
I intend to include my computational model code(s) in its entirety as an appendix in my dissertation. I've gone through my university's formatting guidelines and haven't seen anything on the proper way to format the code in terms of size of font, text-wrapping, spacing, and so forth. What's the best way to do this?
For example, in our prototypesearch engine one of the top results for cellular phone is "", a study whichexplains in great detail the distractions and risk associated with conversingon a cell phone while driving.
Forexample, documents differ internally in their language (both human andprogramming), vocabulary (email addresses, links, zip codes, phone numbers,product numbers), type or format (text, HTML, PDF, images, sounds), andmay even be machine generated (log files or output from a database).
For example, the standard vector space model triesto return the document that most closely approximates the query, giventhat both query and document are vectors defined by their word occurrence.
Whilea complete user evaluation is beyond the scope of this paper, our own experiencewith Google has shown it to produce better results than the major commercialsearch engines for most searches.
However, most of the researchon information retrieval systems is on small well controlled homogeneouscollections such as collections of scientific papers or news stories ona related topic.
In this paper, we presentGoogle, a prototype of a large-scale search engine which makes heavy useof the structure present in hypertext.
It does not provide a "definitive" way to typeset code (there is no such, since there are a number of competing conventions) but its defaults provide a standard and well-recognized formatting that is entirely appropriate for academic publications. Furthermore, it can be customized to follow any unusual requirements of your institutions thesis format.
A good example was OpenText,which was reported to be selling companies the right to be listed at thetop of the search results for particular queries .