Voyant Tools 2

Voyant Tools is now in its second major version, which means that it runs more readily on more devices. While you can use Voyant on-line, the cooler part if running it yourself. Download it from GitHub and give it a try. A huge thanks to Geoffrey Rockwell and Stephan Sinclair and the rest of their group for all the hard work and the commitment to improving Voyant Tools year after year.

All of Us, Everybody

This is the text of the talk I gave before the Alpha Lambda Delta initiation ceremony on Sunday, 2016 April 24.

Let me begin what I assure all of you, parents and inductees alike, will be a brief address with congratulations. Congratulations. You have not only survived the first semester of university, you have thrived. Some of you came to university with an exemplary academic record, and some of you have discovered, or are in the midst of discovering, that you can do well in school and that university is just the kind of school for which you have been longing.

Each of you has your own story. Hold onto it. But you have also begun to recognize, by the friends not sitting with you, that your story is not everyone’s. Some people who did well in high school have not done well in university, and some who persevered and managed to get by either continue to persevere and get by or they just couldn’t quite hold on and they are no longer with us.

So, let me begin today by telling you, based on not only my research but also on the research in education that all those people: the academic successes, those getting by, and those not here in this room this afternoon are all part of our world. That is, I want to celebrate your academic success by also celebrating the diversity of intelligence always all around us.

Let me put it another way, many of you sitting in the front of the room are here because the people in the back of the room made it possible, and many of the people in the back of the room did not do as well academically as you. In fact, many of them were hard on you, harder than you thought necessary, because they did not do as well, they did not get as far as they wanted. And they wanted, and continue to want, more for you. Some of you have been in fact, a little put out by their constant nagging, prodding, urging. I am now going to give you a moment to stand up, turn around, and thank those people in the back of the room.

Those people in the back of the room. Those people. They are a varied lot, aren’t they? Some of them are professionals, like many of you hope to be in three short years. Some of them are tradespeople, mechanics, welders, farmers. And as much as we celebrate your academic success tonight, and as much as university is about developing certain kinds of intelligence and certain kinds of abilities, we also recognize the importance of having all kinds of intelligence and abilities within any given community, within any group of people.

Why am I talking about groups of people when each of you is here because of your individual achievement? Well, first, as I have already hinted, it isn’t entirely individual, and, second, school is weird in always focusing on the individual when it comes to evaluating you and in seemingly always suggesting that your achievement is always within the context of some large institution, that history is a machine whose gears you pass through but do not operate.

As a way to leave you with an idea about how you can be great both individually and with others and how history itself is in your hands, I’d like to tell you a story, a story about a machine that did not exist thirty years ago. It was invented by a bunch of people (all working individually) who mostly didn’t have college degrees. Some of them did. Some of them went to college and decided it wasn’t for them. And some of them never went. But each is important, each of them has a role in the story I am telling you. And, more importantly, all of them were working in the shadow of an idea that had bubbled up out of dozens, hundreds of individuals, each of whom sensed that there was something that could be done, money that could be made.

The story I am telling you is the invention of the crawfish boat, and it happened right here in south Louisiana, and if it doesn’t strike you as important, let me tell you that, first, the crawfish boat makes your eating crawfish at your leisure possible; second, that the crawfish boat is the key to the crawfish industry which is, at present, worth millions of dollars — and those are dollars going into the bank accounts of local people; and, third, that in the current moment a crawfish boat will set you back the same amount of money as a mid-sized car.

Do I have your attention now? A machine locally invented, locally made, selling for around twenty thousand dollars per machine, with those dollars going into local hands, hands like yours.

The crawfish boat as we know it now, with its sleek hull, small engine powering a hydraulic system, and its rear wheel powering its way through rice fields and crawfish ponds has not always looked that way. It began life as five-gallon buckets—one emptying out bait; the other filling up with crawfish—and as kids pools being pulled through fields. The next step in its evolution had a Sears garden tiller powering a variety of cobbled-together wheels. That was followed by small engines powering wheels upfront. And that was followed by moving the wheels to the back, so operators could get over levees. And that was followed by putting idle trailer wheels upfront so that that boats could transport themselves from field to field.

Only in Louisiana, they say. Only in Louisiana can you drive down a highway and pass a boat in the slow lane. A boat not on a trailer but on the road. An amphibious boat. An amphibious boat native to south Louisiana: native because it was imagined by people who live here, made by people who live here, and operated by people who live here.

I am not going to join that long line of people who tell you that here is the best place, that you should never go anywhere else. What I am going to tell you is that places are different and that this is a different place, a place where people come up with some crazy shit, crazy shit that makes sense and makes money.

Different. Not better. And not worse. Different. The men who brought the crawfish boat into existence were different. Any particular one of them could be strictly a farmer, a farmer who fabricates on occasion and only for himself, a farmer who actively fabricates for himself and others, a fabricator who farms or is a member of a farming family, or strictly a fabricator. Out of this assortment of abilities and interests flows a steady stream of innovations and adaptations in response to particular problems.

Together, these men form a dynamic, diffuse network. While each man works alone, separate from the other builders, he is always also working in dialogue with them. The men see each other’s work, and they know what their customers think of the strengths and weaknesses of each design. Most importantly, they recognize imagination in each other, and, in that way, share their creativity. It’s not unlike a guitar player hearing a run or riff, liking it, and including a version of it in his or her next performance. Listening, even indirectly, is what creates an artistic field. Out of such fields comes creativity, as individuals spur each other on, sometimes competitively, sometimes collaboratively.

Creativity never occurs in isolation. We now know that creativity happens always in the company of others. But — and you knew there was a but coming didn’t you? — that doesn’t mean we are never responsible, never ourselves creative. Rather, if you take one thing away from this small story I’ve told you, it’s this: each of you has the power to change the world around you—those crazy farmers and their fabricators did—but the work goes a lot better when you are surrounded by smart, active people. More importantly, it goes even better when you don’t expect all those people to be smart the same way you are. When communities work well, each of us carries a part of the load, but we don’t carry it in the same way. And sometimes, sometimes the man or woman who doesn’t appear to be carrying their fair share … sometimes they are working out a way for all of us to carry less. So, let them have their time. It could very well be worth your time.

That’s my story. It’s the kind of story you would expect from a folklorist, from a person whose job it is to go out and find intelligence and beauty where no one else thinks to look. You could imagine that it’s a lot of pretty talk with a high flying ideals and ideas, but I will tell you this, as someone whose done this work all around the world — here in the United States, in Europe, and in China — and who has worked with CEOs of Fortune 500 companies and that crazy old woman down the street, my story is true. It has always been true. And it will always be true. True for me, and true for you.

So let us tonight honor your achievement, and let your achievement honor the work of others. Always and forever. Amen.

Add Line Numbers to a Text File

I am working on building a list of character states for a possible phylogenetic analysis of this small corpus of legends I have. As I go through the legends and add character states, essentially plot elements (a lot like motifs), I am writing lines like this:

Spirit Controller: [0] absent [2] present
Spirit: [0] absent [1] pirate [2] bull [3] dog [4] wind

Each state/motif needs to be numbered (eventually) so that each text can be described using this list. As I work through the texts, however, I find I am regularly re-ordering the list. At first, I was re-ordering by hand, but I (eventually) realized that I could leave the numbering for later, once I had arrived at a satisfactory sequence.

There are a couple of options for numbering the lines in a text file: cat, nl, and awk, with nl being expressly for the purpose. First, nl:

nl -ba -s ': ' filename > filenamenumbered

Then cat:

cat -n file > file_new

And, finally, awk:

awk '{printf("%5d : %s\n", NR,$0)}' filename > filenamenumbered

I suppose it’s only natural for us humans to want a simple explanation for everything. It’s easier that way, less energy to learn and less energy to remember. It’s really about efficiency, I think.

Louisiana Prepositional Usage

I like the prepositional determinacy of this: “It really is quite adorable to watch her pull up her foot stepstool to the place below the cabinet she needs to be in, and climb on top and get it.” From a paper in my Louisiana Folklore course (April 2015). With that as a start, I couldn’t help but notice more familiar uses: “cook down the onions” and “cut up the meat.”

Turning a Directory of Texts into a List of Strings

For almost everything I do in text analytics, I find myself with a directory of texts which, in most instances, need to be turned into a list of strings, with each text its own item in the list. Here’s my Python boilerplate:

import glob

file_list = glob.glob('../texts' + '/*.txt')

mytexts = []
for filename in file_list:
    with open(filename, 'r', encoding='utf-8') as f:
        mytexts.append(f.read().replace('\n', ' '))

You can double-check your work by simply calling up any given text, using mytexts[1] with the “1” being any number you want, remembering that Python starts counting at 0 and not 1, so your list of 12 texts, for example, will be 0-11.

And if you need to mush all those texts back into a single string:

alltexts = ''.join(mytexts)