Another Look at Our Diplomatic Graph

I wrote yesterday about my network graph about U.S.-Barbary diplomatic relations. The graph I showed was color-coded by nationality. That code was hand-inputted by me, no computation or algorithm necessary.

A perhaps more interesting, and enigmatic, color-coding is the result of running a modularity algorithm in Gephi. This algorithm creates sub-communities from the large network graph. I will not lie: I do not understand the math behind the result. But the communities created by the algorithm are quite interesting.

I find a few things interesting about these communities:

  • James Leander Cathcart and Hasan, dey of Algiers, are in two different communities. This is interesting because Cathcart is probably the person with the most access to Hasan in the entire graph. He was an American captive who worked his way up the ranks into Hasan’s household and became a fairly high-ranking official in the court of the dey. I have two theories for why these communities formed this way. (1) Cathcart’s relationship with the dey was largely informal, not something that got memorialized in writing or official documents. Thus, the “paper trail” on their relationship might be thin. (2) Cathcart did talk a lot to the dey. We know that. But it’s possible that his major contributions to the diplomatic situation in Algiers were not his communications with the dey, but his communications with the outside world. 
  • Many of the European diplomats who were assisting from the outside fall into the same community, which they share with Thomas Jefferson (then-secretary of state). All, or nearly all, of the people in that community were never in Algiers. It makes sense that they would be placed together. The other interesting person in that community is John Lamb, the first American sent to negotiate with Algiers. I’m wondering whether he is in that community because he had much better success dealing with the Europeans than with the dey.

DNAlgiers_communities

 

 

A Graph of Diplomatic Wrangling in Algiers

When the United States became independent after the American Revolution, it had to struggle to protect its seaborne commerce in the Atlantic and Mediterranean. Americans had to rely on the goodwill of France, Portugal, and other European powers because the United States lacked the naval power necessary to protect its own shipping.

Historical Background 

Americans had to negotiate with the Barbary states to secure the release of hostages, taken by Barbary corsairs, and to decide how much tribute would guarantee the safety of American shipping. The United States quickly felt the bite of diplomatic and military impotence. American diplomats, who had little power of their own, had to rely on the good graces of many others with better connections to the Algerine court. Sometimes, those others helped the American cause; at other times, they weren’t all that helpful; and on a few occasions, they purposely derailed American negotiations.

Richard B. Parker writes about the United States’ relationship with Algiers in Uncle Sam in Barbary: A Diplomatic History, which details the complicated and sometimes absurd relationships of American diplomats, European diplomats and dignitaries, and the court of the Algerine dey. The story is quite complex, which makes it difficult to understand in a narrative, and Parker’s organization doesn’t help matters. (A quick shout-out to Jean Bauer, whose Early American Foreign Services Database was extremely helpful in elucidating the roles of some diplomats whom Parker does not adequately identity.)

The story of American-Barbary diplomacy is all about relationships. Naturally, a story about relationships suggests a network graph as a way to make the situation more intelligible.

Parameters and Characteristics of the Graph

To represent the American-Barbary diplomatic network, I created the graph in Gephi. I hate Gephi. I like Gephi. (You know what I mean.) This graph represents interactions from approximately 1785 to 1800. The last interaction I recorded was between the dey of Algiers and William Bainbridge in September 1800; this interaction was the first one in which the navy was directly involved (though it was a diplomatic interaction, not a military one). I decided to end my graph there because I’m most interested in how the navy changed things for U.S. relations with the Barbary states and with the European nations who had hitherto helped those relations.

The nodes are people who had a connection to Barbary diplomacy. The edges are letters and meetings that Parker writes about. I checked up on as many as I could using American State Papers, and I will continue to document the interactions more explicitly than Parker does in his bibliography (where he only records the collection, not the exact document, his source comes from). 

 Each node is color-coded by nationality; the next step is also to record where these people were actually living while they were engaged in Barbary negotiations. 

DNAlgiers
Green: Algiers
Red: United States
Purple: England
Light blue: Tripoli
Darker blue: France
Light purple: Spain
Yellow: Portugal
Orange: Sweden

The graph isn’t perfect (obviously). There’s a lot more to be done here. This graph is based solely on Parker’s book, which I’m not wholly convinced is accurate. In addition, Parker addresses only diplomatic relations with Algiers, not the other three Barbary states (Tripoli, Tunis, and Morocco). Furthermore, I haven’t attached dates to each edge, simply because Parker doesn’t provide dates for all of the interactions. A more dynamic timeline of the network changes would be most instructive. So there’s a lot more data that needs to be added to this graph. But I think it’s a good start toward understanding the global nature of American relations with the Barbary states, which culminated in the Barbary Wars of 1801-1805 and 1815.

 

 

The Lessons of a Bad Network Graph

Spurred by our DH reading group at Northeastern, as well as my general tendency to jump into things before really knowing what I’m doing, I decided a few weeks ago to download Gephi and see what sort of rudimentary networks I could create.

I’d been cataloging the service record of each of my Preble’s Boys officers, setting up the chart so that I could see concurrent service. I started out just looking to see whether any of the Boys had actually served on the same ship as Edward Preble, but as I created the chart (the link here is to a more fleshed-out chart with more comprehensive data), some other patterns began to emerge.

So I thought, let’s plug this into Gephi and see what happens! I set up my network, fumbling through the Gephi readme to set up a very basic network in which the nodes were the officers and the ships were the edges.

I knew what was coming before I rendered the graph as a network visualization, but I was still a little surprised when I saw it. What I saw was a network that I knew from all my research heretofore to be completely false.

[gview file=”http://abbymullen.org/smallnetwork.pdf”]

(I apologize for the crazy way the graph sort of goes off the page. I tried every setting I could find to get it not to do that. Some mysteries of Gephi remain hidden to me.)

My initial reaction was to scrap the whole thing and start my thinking about networks all over. But on further examination, I realized that this graph still had something to teach me.

First, I learned the importance of good data. This graph shows Stephen Decatur as having only two links to anyone, a fact that is false. Additionally, it looks like Edward Preble is almost a tangential figure, a fact that is false. The person with the most links is David Porter, who is an important figure but not that important. So why the graph that looks like this?

Simply put, this is a bad data set. It starts to get at my question (How do these people link together?) by a very small subset of their interactions with each other. I don’t even have complete service records for some of these men, so it’s possible that there are connections missing from my chart. In addition, these men had several levels of interaction beyond just concurrent service (squadron concurrent service, shoreside interaction, correspondence, indirect influences…the list goes on). So the data set is quite incomplete.

What this bad data set teaches me is that the meaningful network of these men is going to be quite complex. It’s likely to need to be organized on several different interaction levels, as well as interactions over time and even perhaps spatially (do men feel others’ influence more when they’re at sea than when they are landbound? I don’t know).

Second, I saw new connections, forged through unintended groupings. Since this is a bad graph, it’s tempting to say that all the links it made between people are bogus. However, I realized that there is at least one interesting phenomenon going on that I hadn’t thought of before, but that perhaps is borne out by the documentary evidence.

This phenomenon, which may actually be a real breakthrough in my analysis, is the appearance of two groups. If you draw a connection between Stephen Decatur and Edward Preble (in your mind), then you see the loose formation of a group around them. The graph already shows a clique: the group with David Porter and William Bainbridge. What’s the connection between these two groups?

Interestingly, the two groups roughly fall into (1) those who were aboard the USS Philadelphia when it grounded in Tripoli Harbor, and (2) those who volunteered for the mission led by Stephen Decatur to destroy the Philadelphia. There are some outliers, officers who were not involved in that series of events in any way (Lewis Warrington, for instance), and one interesting anomaly, Charles Stewart, who was not aboard the Philadelphia, though he is well-ensconced into that group of officers. It will be interesting to see what happens to those men once there’s more data.

Without having done any other research yet into this grouping, I have an inkling that this way of looking at Preble’s Boys may show more about their careers after 1803 than their link to Edward Preble.

 

So what’s the major lesson for me? When I next take on Gephi, I’ll be armed with a lot more data, but even if the results are surprising, I’ll be keeping my eyes open for possibilities that I didn’t see coming down the pike.

I’d welcome any other insights on my first foray into network analysis.