pedagogy

On Teaching Literature to Computer Science Students

[Previously: On Teaching Coding to English Studies Students]

Recently I wrote about English studies students learning to code in an interdisciplinary computer science and English class. In that post I mentioned that this class (running for the third consecutive year) comes with a variety of challenges – some strictly institutional, some cross-departmental, and some pedagogical. I’ve been collecting a number of these and will be blogging about them in the future. In that post I also mentioned that there are two very oppositional learning curves at play: one is getting the English studies students to think about computers in a critical way and the other is getting the computer science students to read literature.

We have just hit the very exciting point in the course where the computer science students are learning to read and the English studies students are truly hitting their stride, which is a dramatic turnaround from the start of the course. Last week we asked each group to give a very short, informal presentation about their assigned Shakespeare plays in relation to the rest of the Shakespeare corpus. It was no surprise that in every group the English studies students gave an overview of the plot of their play and a few key themes whereas the computer science students reported what they had deemed to be a finding. English studies students have been studying how to analyze texts and the computer science students haven’t done that in the same way.

Here in Scotland, students begin to track either towards arts & humanities or science long before they hit university – they start to track in high school, and take school leaving exams in a number of subjects (“Highers”), from a rather long list which you can read here. Once you choose your track, it’s rare (though not unheard of) to have much overlap between A&H and science in one’s Highers qualifications. Most degree programs will have preferred subjects for applicants which guide students’ decisions about which Highers to take; Strathclyde’s entry requirements for a student wishing to be a Computer Science undergraduate can be found here (pdf). Unless you’re going into a joint honours in Computer Science and Law, English literature or language is not a required Higher for prospective students in computer science at my university. It goes the other way, too – a Higher in Maths is not a requirement for a prospective English studies student unless they plan on taking a joint honours with Mathematics (again, pdf). Some students may take Highers strictly out of interest (or uncertainty about which route to take), but like the SAT II or AP exams, this is not necessarily something you’d do for fun – these are high-stakes exams.

If faced with that choice I would definitely have taken the Arts & Humanities track despite liking science and being (told I was) very bad at math. I suspect that a lot of computer science students may have liked history or media studies but were bad at writing (or told they were…) and that was enough to turn them away from taking an Arts & Humanities track. It might be that students who sign up for a degree in Computer Science are just really passionate about computers, or that they like practical problem solving, or they’ve been told that computer science is a lucrative field. I have no idea – I’m not them*. On the surface, it can look like they have a lot of missing cultural information for not knowing things about literature – but they also know a whole lot more than we do about very different things.

That’s not to say these students don’t read of their own accord or aren’t interested in books. However, by the time they show up to my class, they have rather successfully avoided close reading for a few years, whereas English studies students have been practicing this skill for a while now. This is something English studies students are very comfortable with, and have now learned enough about the way that computers “think” (or lack thereof) to reach a common ground with the CS students.

However, in the same way the computer science students found the first half of the class easy and the English studies students found it tremendously daunting, the computer science students suddenly feel like they’ve been thrown in the deep end. The English studies students have to teach them how to analyze a text.

In our in-class presentations, each group had to discuss a discovery they’ve made about their play and explain why it was interesting. Without fail, the computer science students had lots to say about various discoveries they had found about kinds of words that were more or less frequent in their play compared to all of Shakespeare’s plays. And yet when they were pressed about why they thought it was happening, they weren’t really sure. The English studies students could postulate theories about why there were more or less of a specific kind of feature in their text, because they know how to approach this problem.

Over the next few weeks we’re letting the students self-guide their own projects and produce explanations for their discoveries, which means the computer science students are on a crash course on close-reading from their in-group local expert. They’re learning that data isn’t everything when it comes to understanding what makes their play in some way different (or similar) from other plays. In fact, they’re learning the limitations of data and ways that close-reading is not just supplementary but essential to a model of distance reading with computational methods. And if the student presentations I saw last week are any indication, I suspect I have some very exciting work coming my way in a few weeks’ time.

* I did my dual-major undergrad degree in English lit and Linguistics; I didn’t get involved in computers until my masters.

(with thanks to Kat Gupta for comments on this post)

On teaching coding to English studies students

[see also: On Teaching Literature to Computer Science Students]

This term I am teaching English studies students how to code. This seemingly goes against quite a lot that I’ve been saying online for a while, so let me back up.

I’ve been involved in an interdisciplinary digital humanities course called Textlab for the past two years, as part of a university-sponsored, research-oriented, cross-faculty project; this time around I’ve stepped into a larger role of co-convening rather than simply being support staff for it. (It’s week 2 and I’m already planning a blog post called Things I Learned From Co-Convening A Interdisciplinary, Interyear Course, so stay tuned for that.) The premise of Textlab is that Computer Science and English studies will work together in small groups which study a specific Shakespeare play with computational and literary methods (for what this looks like in practice, please see this paper). The goals of knowledge exchange here is pretty clear: English studies students learn hands-on computer skills and the computer science students learn how to practically apply their knowledge on a real-world project. In essence, the computer science students have to revisit Literature and the English studies students learn Computers. The learning curve on both sides is, effectively, massive.

In many ways the first half of this course is digital literacies for the English studies students and literacy literacies for the Computer Science students in the latter half of the 10 week course. We are obviously covering a lot of ground here; in the past we have had students blogging and wiki-ing and tweeting, but this year we’re scaling back to address textual analysis from the ground up, what that looks like, and how computers can supplement our literary understandings of texts.

Because this is a practical, hands-on, interdisciplinary class, the students all need to be on roughly the same page early on. And that is how I end up back with teaching English studies students how to code – we are starting with really basic Unix commands to understand how computers work, and build on these principles of commands to programs to understanding how computers can supplement human inquiry. Predictably, the CS students fly through the early Unix stuff and can really struggle with the reading, whereas the English studies students succeed wildly with the reading stuff and can really struggle with the computational stuff.

I’ve been sitting on a blog post for a long time about why I don’t think everyone needs to learn how to code and I continue to think that. This blog post may never see the light of Internet-Day; we’ll see. But the main thing I want to highlight is that I have no “official” training in programming or coding; my degrees are all in literature and linguistics and I have self-taught myself almost everything I know about computational analysis now. Three years ago I couldn’t have told you what a command line is and now I deal with it on a semi-regular basis. So I totally understand where the English studies students are coming from, and I also understand the potential of what the computer science students are capable of. The problem in much of the Everyone Must Learn to Code Now dogma is that you need a practical problem to care about, otherwise it is essentially meaningless. I don’t really care that Mary has three watermelons and Jane has seven oranges and how many apples does John have? Learning to code is all very well & good but the practical aspect has to be there, otherwise it just feels like our fruit distribution word problem.

So as I sat in the computer lab today with my students, I saw the English studies students struggling with commands like wc, -l, -w, mkdir, uniq, grep, cat. Part of the problem was that the students had no conception of why they were typing these letters into some computer. “I don’t understand,” they said. So I asked them what they had done so far, and they said they had just typed in some things and now they aren’t sure what to do with it.

We sat down and talked about what each step was, and what each of these commands meant, while walking through parts of the lab together. Sometimes they weren’t sure, and we had to address what to do about that. “Cat” is not a very googleable command: we aren’t looking for furry creatures with pointy ears and whiskers. But as a command, cat does a lot and what it does is not super transparent, so we talked about how to get information about what these letters mean.

The other thing I found a lot of my English studies students doing was feeling self-conscious about not knowing how to go back and fix what they understood to be a mistake. It’s easy enough to go back to the folder we are working in, but we hadn’t given them that command and there’s no easy BACK button in a terminal. Here’s a secret about me: I always have to look this up. I have to look up a lot of information when I want to do something computational. I would never claim to be a programmer, let alone a proficient one, but even after three years of this kind of stuff I have to look it up. One of the big problems they were having is that they didn’t know how, or where, to get that kind of information, so we talked about that too.

I don’t like or support the idea that computational language is like a natural language (it’s not) but the easiest analogy to make here is that learning what these letters mean is a lot like learning a language. If you’re learning French you need to know what the sounds you’re mashing together represent, and what kind of meaning they hold. Je voudrai un ananas may be meaningless to an English speaker, but to a French speaker that phrase holds meaning. Likewise, asking a computer sort -n file | uniq | sort –r > sorted_file holds a specific kind of meaning. If you don’t speak French you probably don’t understand what I just said; if you don’t speak “computer” you don’t understand what you just said either. Simply replicating letters in order doesn’t allow the students to critically engage with a task the way we might want it to. The goal of the course is to get the English studies students to understand how a computer works more fully, but producing replication tasks makes this just another black box: type this, MAGIC HAPPENS, you will have results.

Next week we are addressing pipelines more fully. My role as a teacher, educator, and mentor is to help my students understand what we’re doing, and one of the many ways this class is challenging is that I don’t want to be standing in front of them lecturing if I can avoid it. Standing in front of my students and telling them how to do things isn’t hands-on learning. But talking about how to find resources and how to ask questions is hands-on learning. In the meantime, I am thinking about how I can support the computer science students when the coin is flipped and getting them talking about literature in a way that feels tangible and relevant to them.