New tutorials on network analysis with Cytoscape

The Cytoscape interface, featuring a pane on the left with buttons and a graph diagram on the right
I find the Cytoscape interface more intuitive than Gephi’s, although in both cases, you need to have a basic understanding of key NA terms.

For some reason I got it into my head to write a bunch of tutorials on using Cytoscape for network analysis. They’re now all up on Github. (I’ve been moving to Github for tutorials because they’re easier to update there.)

I started writing these for the students in my spring-quarter class and, even though the class is over, I’ve been adding to them compulsively. They’ll take you from zero to an interactive, web-based network graph, with stops along the way for projecting a two-mode network to a one-mode network and working with node attributes. (If you don’t know what any of that stuff means, they explain that, too.)

There’s a bit of a Gephi-versus-Cytoscape battle right now among people who do network analysis. I actually started out on Cytoscape, only because I found it slightly more intuitive, and switched to Gephi when I discovered most people used that. But in recent years, I’ve had a really hard time dealing with Gephi. First, there was the Legendary Java Problem, and although the new version is purportedly more stable, I actually just cannot get it to work on my Mac and have frankly kind of lost the will to keep trying.

Cytoscape is Fine. It’s designed for scientists, really, and other people who care very much about statistical measures of networks, which to be honest, I don’t really care that much about. (I don’t think most humanists trust these measures anyway, so I don’t see much point in hammering on them.) I find Cytoscape’s web service, CyNetShare, to be pretty janky-looking, but … you can interact with the network diagram, so that’s good, I guess.

To be honest, I’ve been slowly making the switch from Gephi/Cytoscape/etc. to R’s igraph package, and to D3 for displaying networks on the web, just because they’re so much nicer looking. One thing I like about Cytoscape is that after you’ve measured various aspects of your network, you can export JSON that’s set up specifically for D3’s popular force-layout network.

When I was visiting Stanford last winter, I got to see a preview of a network analysis tool that the Humanities + Design team is building, and I really liked the way they placed the emphasis on exploration and discovery, rather than statistical measures. I’ll be looking forward to seeing the release of that tool (I think it’s called Idiographic?), since I do feel that humanists have different interests when it comes to networks than scientists or social scientists.

What’s in your conference travel bag?

A red purse sits in the backyard. In front are a laptop, notebag, pens, two small gray zippered pouches, a power adapter, a power strap, a pill case, and a striped pouch.
Taken in a hotel room, appropriately. Iphone not pictured, since I had to take the picture somehow.

Anyone else have a weakness for those “What’s in your bag?” features? My stuff is not nearly as nice as the stuff those people carry, but deep in my heart, I seem to cling to the belief that my life really would be better if I could just optimize a few things.

Anyway, I posted on Facebook about a new receipt-filing thing I’d bought, and the response was so enthusiastic (what is wrong with my friends?) that I thought I’d do a quick post about what I’ve been carrying lately. I’ve been traveling for work a ton this year (way too much, obviously) and I’ve been devoting more thought than I’d like to admit to making my conference travel bag efficient.

Continue reading “What’s in your conference travel bag?”

Basics of Creating a Scroll Kit Narrative

My Digital Labor, Urban Space, and Materiality class will be using the drag-and-drop framework Scroll Kit to create multimedia “device narratives.” Here’s the tutorial I’ve created to teach them to use Scroll Kit. You’re welcome to download these instructions as a PDF or as a Word document, in case you’d like to modify them. 

This is my first Scroll Kit tutorial; the second covers the parallax effect.

With Scroll Kit, you can create multimedia works in a scrolling format suitable for long-form narratives. It’s easy to drag and drop elements to create interesting effects. Your project will have a unique Scroll Kit URL, so you can share your project widely (or you can export the code).

Some examples of projects created with Scroll Kit:

Continue reading “Basics of Creating a Scroll Kit Narrative”

A dead-simple weekly email: A little workflow for bringing people together

UCLA’s Digital Humanities program, which I coordinate, is interdisciplinary in the extreme. Unlike some other programs, which sit in English or History departments, UCLA DH is an entity unto itself: a standalone minor and graduate certificate housed within the division of the humanities. In a lot of ways, this is great: We have no particular allegiance to any one department, and our students and faculty come from all over the university.

But they’ve all got a lot of stuff going on, and in many cases, they see their primary home as a different department. (I’m the only person at UCLA who’s dedicated full-time to the DH academic program.) We don’t have a dedicated community space just for the DH program, and while I organize as many events as I can on our limited budget, people just don’t have a ton of time to hang out or attend events.

And yet part of my job is to create a sense of community for the program. What to do?

I’m still working on it, but I have come up with one modestly successful tool: a weekly email digest that gathers events, job opportunities, fellowships, CFPs, and resources relevant to UCLA digital humanities, prefaced by a little introduction from me.

Here’s what one looks like.

This is why I do it:

Continue reading “A dead-simple weekly email: A little workflow for bringing people together”

Using Mozilla Popcorn Maker to Create an Interactive Video

I’ll be teaching a workshop on Mozilla Popcorn Maker soon and, as is my habit, I created this step-by-step tutorial. Here’s the tutorial in handout form as a PDF, and here it is in Word, in case you’d like to modify it.

Mozilla Popcorn Maker allows you to enrich a video with interactive maps, images, and webpages. Your video could be different every time it’s played, because it pulls in dynamic content and allows your “viewer” to interact with it. Here, we learn how to use it to enhance an archival video.

Continue reading “Using Mozilla Popcorn Maker to Create an Interactive Video”

Very basic strategies for interpreting results from the Topic Modeling Tool

Written with Andy Wallace, with methods and ideas borrowed from Zoe Borovsky

Many plastic tubs of Play-Doh, each a different color.
As Zoe Borovsky brilliantly demonstrated when she visited my DH grad class, topic modeling starts with the assumption that each document is made up of multiple topics — like lumps of Play-Doh. Photo: “Play-Doh” by dbrekke.

If you’re reading this, you may know that topic modeling is a method for finding and tracing clusters of words (called “topics” in shorthand) in large bodies of texts. Topic modeling has achieved some popularity with digital humanities scholars, partly because it offers some meaningful improvements to simple word-frequency counts, and partly because of the arrival of some relatively easy-to-use tools for topic modeling.

MALLET, a package of Java code, is one of those tools. It’s not hard to run, but you do need to use the command line. For those who aren’t quite ready for that, there’s the Topic Modeling Tool, which implements MALLET in a graphical user interface (GUI), meaning you can plug files in and receive output without entering a line of code.

David Newman and Arun Balagopalan, who developed the TMT, have done us all a great service. But they may also have created a monster. The barrier for running the TMT is so low that it’s entirely possible to run a topic modeling test and produce results without having much idea what you’re doing or what the results mean.

So is it still worth doing? I think so. Playing with the results by altering variables and rerunning the test can be a useful way to get your head around what topic modeling is and isn’t. And, as I recently tried to convince my graduate DH class, screwing around with texts — even if you’re not totally sure what you’re doing — can be a surprisingly effective way of getting a new perspective on a body of work. Finally, seeing how many decisions need to be made about  texts and variables is a great way to understand that topic modeling is not a way of revealing any objective “truth” about a text; instead, it’s a way of deriving a certain kind of meaning — which still needs to be interpreted and interrogated.

But in order to get any of these benefits from the Topic Modeling Tool, you need to be able to make some sense of your results, which is no easy task. The TMT generates some decidedly cryptic-looking files, and as far as I can tell, there aren’t many resources out there to help you make sense of them.

Once you survey the results of the Topic Modeling Tool, it becomes clear why topic modeling often goes hand-in-hand with visualization. The format of the results makes it difficult for a human being to discern patterns in them, and the files aren’t easy to visualize without doing some custom coding.

But say you’re a non-coder using the Topic Modeling Tool to screw around. You feed it some text, you get some files; now what?

What follows are some very basic ways you might begin looking at the results you’ve generated.

Continue reading “Very basic strategies for interpreting results from the Topic Modeling Tool”

Use Automator to combine your research photos into one PDF

By request, these are updated instructions for using your Mac to combine your research photos into a PDF. For more on digital research workflows, see here, here, and here.

If you have a Mac, you own a robot! It’s called Automator and it lives in your Applications folder. It does pretty much what the name implies: It bundles little actions and makes them easy to repeat and perform on a lot of files. Here, I’ll show you how to use Automator to combine a bunch of research photos into one PDF.

Open Automator


It lives in your Applications folder.

From the pop-up menu, select Workflow


Choosing Workflow means that in order to run your series of actions, you’ll open up Automator first. (It’s kind of fun to experiment with Application, too! That means that to your series of actions becomes a standalone application. To run it, you double-click on your icon or drag some files onto it. But for now, let’s keep it simple and stick with Workflow.)

Let’s investigate!


The Automator interface is actually pretty simple. The far left pane (1) contains categories of actions you might want to run. The second pane (2) contains the actions themselves: things like “Add Songs to Playlist” and “Combine Excel Files.” You can assemble actions into sequences by dragging them from pane 2 into pane 3, in the order you want to run them. So, really, not too complicated!

Assemble your actions (1)


First, you need a way to feed Automator the files you want it to alter. Under the Files and Folders category in pane 1, find the Ask for Finder Items action in pane 2 and drag it into pane 3. This means that the first thing that Automator will do is ask you which files you want it to modify. Because you’ll be modifying multiple files, check the Allow Multiple Selction box.

Assemble your actions (2)


Happily, the latest version of Automator comes with an action that does exactly what we want! Under the PDFs category in pane 1, you’ll find an action called New PDF from Images. Select it and drag it into pane 3. In the Output File Name box, call it something that makes sense to you. You can even tell Automator where to save your new PDF, if you want.

Run your workflow


Click on the Run button, which you’ll find in the top right-hand corner of your Automator window. Automator will ask you to select the photos you want to modify (hold down Command-A to select all the photos in a folder) and then it’ll run your actions!

You’ve got one big PDF!


Unless you specified a different place to save it, your big PDF should be waiting for you on your desktop, simple as that. Cool, huh?

Save your workflow


Since you’ll probably want to do this again, select File, then Save, so you can perform these actions again later. You can save it as a Workflow, or, if you don’t want to have to open up Automator every time you perform your action, you can save it as an Application.

Play with some options


Automator does a lot of cool stuff, and it’s fun to just play around with it. For example, you can make your PDF easier to find with Spotlight by using the Set PDF Metadata action (in the PDFs category). Give it a shot! You won’t break anything.


Research tools redux: What I use

Photo of archival binders
Photo by pixelhut

I posted recently about tools for managing a research workflow, and one of the points I made is that no set of tools will be right for everyone. I’ve tried and failed to foist my favorite tools on enough people to know that this is true.

Still, after I wrote the post, a few people asked me which tools I use. I do indeed have a number of favored tools, and since I find myself endlessly fascinating, I enjoyed the chance to consider why I use them and what it says about me as a researcher. I’d also really love to hear what you use and why!

Here’s what I use in a nutshell:

I haven’t used DEVONthink much in the past, but after giving it a more concentrated trial for my last post, I suspect it will make its way into my workflow, too.

Here’s why these tools work for me:

Continue reading “Research tools redux: What I use”

Embarrassments of riches: Managing research assets

Last updated May 15, 2013

There’s research, there’s writing, and then there’s that netherworld in between: wrangling all the digital files you gather over the course of your work. Digital files are often easier to deal with than stacks of paper, but they can also proliferate frighteningly quickly.

I teach a workshop on this topic, catchily titled Managing Research Assets (better names welcome). Below is a digital version of the workshop handout, followed by a link dump of my favorite posts about developing and refining digital research workflows. You can also download a PDF version of my handout, or a Word version if you’d like to modify it.

Continue reading “Embarrassments of riches: Managing research assets”

Install WordPress on your Mac

This week, I’m teaching a Hack Your WordPress Theme workshop for Emory’s Digital Scholarship Commons. It’s fun (and not all that hard) to customize WordPress themes. The only problem is, in order to really access the theme files, you need to install WordPress on a server. But what if you’re not quite ready for that?

You can still play around with WordPress by getting your own computer to act like a server. Your WordPress site won’t be public, but you can make changes to your theme and, when you’re ready, upload it to a real server.

XAMPP is a software package that emulates a server on your own computer. Don’t worry, it’s not hard to install — there are just a couple tricky steps.

Continue reading “Install WordPress on your Mac”