Does LaTeX count as “programming”?

Today I wanted to talk about a common question I come across: Does LaTeX count as programming? Many people dismiss this question directly with a no. But I say the answer is not that simple and depending on how you practice LaTeX can definitely be ‘yes’ much more than you might think! Also, something I really don’t appreciate is people meaning to  degrade LaTeX when saying using LaTeX has nothing to do with programming (because it does and most people who think that way have just never seen LaTeX being used more like programming). LaTeX is, strictly speaking, a programming language and Turing-complete. Or rather, LaTeX is a macro package for TeX which is the actual Turing complete programming language. The typesetting-specific tools LaTeX provides probably can’t, however, be considered a full programming language on their own anymore. You could theoretically do anything with it, though it might just not be the easiest possible way to accomplish your ends (unless

read more Does LaTeX count as “programming”?

Learning to program: Failing fast and error messages

Today I wanted to talk about error messages and why you should learn to love them. If your mission is to learn programming, they show you your weakness and tackling a weakness is always the fastest way to learn. This is why the whole discussion of fixing error messages quickly turns into a philosophical discussion of a way of life: Walking the  path of the Ninja requires you to fail fast, early on, and often. Let me tell you why… Should you care about error messages and warnings? Are they secret messages from the universe? Yes, they are. If you’ve never given a hoot about errors and warnings in your life, congratulations. I don’t either. That is, until the thing doesn’t compile anymore. I am at awe with respect for people who fix mistakes before they become a problem. But I’m not one of them. What does this mean, however, with regard to your attitude towards failure? It probably means

read more Learning to program: Failing fast and error messages

LaTeX for Archaeologists: An archaeological catalogue using LaTeX

Like hinted in various Noob posts, our friend the LaTeX Noob once asked for help typesetting her archaeological catalogue using LaTeX. As it sadly happens to me quite often, I totally forgot about this and was reminded by a recent inquiry (don’t be afraid to ask if I forget to post something I once promised!). In this post, I wanted to share the reaons why you should use LaTeX to typeset an image-heavy catalogue and what to take into account when deciding how to implement it in LaTeX. General PhD typesetting advice One PhD thesis = 2 outputs In the post on LaTeX for PhDs, I have already laid out the most common and some more commonly overlooked advice on why you should use LaTeX for typesetting your PhD thesis. An important aspect is that your thesis will likely generate two outpts, the thesis and a book (hopefully). If you “hard-code” everything now, the transition won’t be as smooth as

read more LaTeX for Archaeologists: An archaeological catalogue using LaTeX

An ‘Inline’ bib. file using filecontents

In this post, I will explain how you can use the filecontents package to create an ‘inline’ .bib file inside your main document.tex . This can, for example, be useful if your LaTeX gets compiled on a server and your method only allows you to pass one single document. If you wanted to pass a .bib file with it, this wouldn’t work out. Also, for LaTeX releases past fall 2019, the package is no longer required for this functionality, you can use it directly as an environment. I’ll still keep this the way I wrote it. See the documentation here. Premlinaries: How I ended up writing this That’s what I initially wrote this little method for: Our publication system archives data following the single source principle: This means that all representations you want, such as a web site or an output PDF, will be generated from one single document. In our content management system, my data are encoded in TEI

read more An ‘Inline’ bib. file using filecontents

Learning to program: What to do if the program doesn’t compile

In this new year, I wanted to make an introduction to programming which mentions all the parts which (albeit being quite essential) many of the other tutorials, books and teaching documents tend to leave out. Things like “How do I even start debugging?” or “How to not lose it if my program doesn’t compile or when nothing works anymore?”. I was fortunate to get taught these skills by friends and helpful colleagues but if you’re a remote-only learner and don’t have access to such people – this series is for you. In this first post, I’ll address the problem that you’re in a situation where your program does not work at all. In the case of LaTeX, this means it won’t compile. Other programming languages which are not compiled will just not run. So what do you do in that dire situation? Step 1: Take a deep breath Stay calm. I repeat, stay calm. Take a deep breath. It’s just

read more Learning to program: What to do if the program doesn’t compile

Strategically Using Search-And-Replace for LaTeX documents. Part I

In an earlier post, we talked about the perks of using search and replace wisely on XML documents. Here I want to argue that search and replace might be even more powerful when used in LaTeX.   The power of search and replace Imagine your thesis advisor decides last minute that they don’t like the way images are typeset in your thesis. It happens. We are speaking from our friend the Noob’s experience here. So imagine your advisor decides the images in your archaeological catalogue are too small, at the very last minute. In Microsoft Word, problem No. 1 you would have already encountered before now is that the document probably wouldn’t even open anymore (what with 200 pages full of images etc.). The second problem would be that you’d have to change each image size by hand, clicking and dragging around, cleaning up after the horrible mess and destruction your changes are leaving behind. In LaTeX, thanks goodness we

read more Strategically Using Search-And-Replace for LaTeX documents. Part I

Understanding Scalability and Relative Values

What is the difference between 12pt and “format as heading“? Between 50px or 0.5\textwidth? Most of us know that we should always prefer relative to absolute values. But many who are new to webdesign or LaTeX don’t really get why. All of us who typeset papers and conference proceedings know that years of using MS Word does not necessarily teach you that difference either. This short post will try to remedy this in a quick and painless way 😉 In a WYSIWYG texteditor: Fontsize 12pt or “Format as Heading” In the case of a text editor, it is advisable to use the format templates rather than manually changing headings and so on for simple reasons: The information is stored as markup and if we tell the program what we want formatted as a heading, the machine gets semantic information about the text. Most people will understand that something is meant to be a heading when the font size is manually

read more Understanding Scalability and Relative Values

The LaTeX Ninja: Topics and the pseudonym

Since starting this blog about a year ago, I am at a point where I think my choice of typical topics is more or less stable. I also have used the WordPress “categories” to add many of these topics and also hope to develop some of them into some sort of series. What these ‘series’ are for, is explained in the category descriptions now. The Ninja: A pseudonym Also, I wanted to quickly address another thing: My pseudonym. I have already talked about why I started this blog multiple times before. There is a basic mission statement in the about section. Long story short, the ‘LaTeX Ninja’ was a goal, not a label I put on myself. It doesn’t describe ultimate LaTeX wisdom (for that, I have sometimes used the term ‘LaTeX Guru’). If the LaTeX journey you can join on this blog were a computer game, you you start out as a ‘LaTeX Noob’. As you gain experience, you

read more The LaTeX Ninja: Topics and the pseudonym

A systematic training progression for programming?

As some of you might know, I am currently a fellow, aka at my personal writing retreat at Wolfenbüttel. And I decided to combine this with some sort of a training camp for my bouldering progress because you do need to have some breaks from writing during the day anyway and I can’t always watch Bones or create CV templates. You might have been following some of my bouldering on epigrammetry, the blog, or epigrammetry, the Twitter.   Training progressions in sports Also very few of you might know as well, I used to train a lot for long-distance running (10k) during my teens. So I know what training progressions are. I used to have detailled training plans, eating regimes, supplements to take and all that jazz. I stopped at some point because my immune system kept bullshitting me and as an ambitious person, I couldn’t take the idea of having to start from scratch after a half-year of being

read more A systematic training progression for programming?