Category Archives: homework

Self-Portrait in Data

Our assignment last week for Crafting with Data was as follows:

“Self-Portrait: Data is factual information; science finds its story. But data isn’t only about science so we can turn that on its head. Find data for your own story. Create a self-portrait, using data.”

I thought this would be a cinch, as I keep somewhat obsessive records about a lot of stupid stuff. However, I underestimated the inconsistency of my recordkeeping, and the difficulty of presenting awkward data in some coherent fashion, so when the fab Nicholas Felton came to talk to our class and see what we’d done, I had nothing yet to show. Bummer. But here’s what I finally came up with.

Foods

Self-Portrait in Data: Foods

To give you some perspective on how poorly I eat. These are servings, over the course of September 2009. Data came only from my diary, in which some days are blank and others obviously incomplete. But I think the overall gist is accurate. To wit: I had cheese about every three days, less than one serving of fruit or vegetables per day, and more than one dessert per day, much of it cake.

Mmmm, cake.

Beverages

Self-Portrait in Data: Beverages

I do much better with drinking than with eating, especially if you consider that I rarely remember to keep track of glasses of water—it’s my favorite beverage, and I definitely drink more of it than is shown here. Data came only from my diary, in which some days are blank and others obviously incomplete. So, according to my crappy records, I had only thirty-nine eight-ounce servings of water over the course of September 2009; I’d guess the real figure is at least three times that. The tea counts—38 black, 11 green, 4 herbal—are probably also way too low. Everything else is probably pretty accurate.

I know that I had exactly three beers, for instance (two bottles of Brooklyn Brown and a can of Murphy’s Stout), and I can’t have had more than three glasses of wine, because it was on the same evening as two of the beers—at a wedding—and I would have fallen down if I’d had more. Cheap date.

Update, 9/10

Rob wanted to know why I made this a pie chart. I guess the reason was that I felt that the relationship of each part to the whole was the most important; I was thinking in percentages, and a pie chart is, for me, the most intuitive way to visualize percentages. Which probably just means my vocabulary of types of charts is too limited.

Social

Self-Portrait in Data: Social
(Click for a bigger image.)

Here are my interactions with friends and family during the month of September 2009. I was surprised that face-to-face interactions outweighed all others, since I feel like I hardly ever see anybody, but I think the e-mail numbers would have kicked face-to-face’s ass had I not gone to a wedding where I knew a lot of people.

The height of each block represents days of interaction (DoI). That is, if I exchanged a dozen e-mail messages with Elisabeth on Monday and three on Tuesday, and also on Tuesday I got two from Jack, it counts as three DoI: Elisabeth x 2 + Jack x 1.

The width of each block represents the number of people I interacted with using the method in question. There were seventy-six people altogether; I met thirty-one face to face, and only one sent a note through LinkedIn. Four people called, texted, or left Flickr comments.

This data came from my diary, from copies of DMs in my e-mail account, and from Twistory, which shows all the tweets I sent to people on my Google Calendar. I did not have the patience to page back through all the actual Twitter messages, so I may have failed to count some tweets that were sent to me. I delete most text messages from my phone upon reading them, so those are noted only when I knew I exchanged some—e.g., when I was coordinating with friends about wedding transportation, and when Elisabeth was visiting New York (yay!). I think I counted Flickr comments on only one of my two accounts; oops.

Update, 9/10

So, in class on Thursday, people seemed to feel that the way I’d presented this data was . . . misleading? Not sure that’s the right word. In particular, Rob had trouble with the notion of Days of Interaction, I think. People would rather have seen real quantities of e-mail and so forth, separated into in/out? Yes, I’d like to see that, too, but I didn’t want to spend a million hours gathering the data; as it was, this took me more time than I’ve spent on any other homework so far this semester. And probably it should be a double-bar chart instead of using the number of people in each category to influence the area of the bar.

I felt when I made this that it wasn’t the right sort of chart to represent this information, but to me it’s meaningful enough. It tells me that I see a lot more people than I think I do, and that I really ought to get rid of my land line, now that I’ve managed to get Mom to call my Google Voice number 99 percent of the time. I expect the SMS numbers will start going up, now that I’m using a phone with a keyboard; it was just too slow before, and I’d sometimes get halfway through a message and then delete it and just call, though I hate talking on the phone.

Conclusion

So, I’m a near-teetotaler on the verge of getting scurvy who mostly stays in touch with people electronically.

Living in uninteresting times

don’t press the red button

This week’s assignment for Crafting with Data was

Use an Arduino to gather 500 samples of interesting data in two different conditions (1000 samples total). Post your data online so it can be downloaded.

Now, see, I did this assignment uncharacteristically promptly—days ago!—without having noticed the adjective interesting, so originally what I had was some profoundly dull numbers from a thermistor, measured (a) under my fluorescent proofreading lamp and (b) while I held the sensor between my fingers. You will thank me, therefore, for rereading the assignment, noting my error, and, at the last minute, using the Pong controller I made for Understanding Networks to gather some slightly less dull information from the x axis of an accelerometer: (a) walking on level floor, and (b) climbing up and down stairs.

Now, with charts!

accelerometer readings while walking on level floor

accelerometer readings while climbing stairs

The guts of my beautiful data collection device look like this:

Pong controller guts
(Click the photo for more details at Flickr.)

I used two Processing sketches—for the thermistor data, Rob’s code; for the accelerometer data, a quick-and-dirty mod of the almost wholly unoriginal code I used for the Understanding Networks assignment.

[java]
/*
Serial String Reader + Simple net Client
Language: Processing

Reads in a string of characters from a serial port until
it gets a linefeed (ASCII 10). Then splits the string into
sections separated by commas. Then converts the sections to ints,
and prints them out.

* Starts a network client that connects to a server on port 8080,
* sends any keystrokes pressed.

created 2 Jun 2005
modified 6 Aug 2008
by Tom Igoe
modified 24 September 2009 by India Amos
*/

import processing.serial.*; // import the Processing serial library
import processing.net.*; // import the Processing networking library

Serial myPort; // The serial port

Client myClient; // instance of the net Client
String data; // string to hold incoming data
String ipAddress = “128.122.151.178”; // address of the server
String myKey1; // the virtual keypress generated by the x-pin of the accelerometer
String myKey2; // the virtual keypress generated by the y-pin of the accelerometer
String myKey3; // the virtual keypress generated by the switch
String myKeyBuffer; // all the virtual keys pressed by a single bleat from the Arduino

float bgcolor; // Background color

void setup() {
// establish the background and foreground:
size(200, 200);
background(50);
fill(200);

// Connect to server on port 8080
myClient = new Client(this, ipAddress, 8080);

// List all the available serial ports
println(Serial.list());

// I know that the first port in the serial list on my mac
// is always my Arduino module, so I open Serial.list()[0].
// Change the 0 to the appropriate number of the serial port
// that your microcontroller is attached to.
myPort = new Serial(this, Serial.list()[0], 9600);

// read bytes into a buffer until you get a linefeed (ASCII 10):
myPort.bufferUntil(‘\n’);
}

void draw() {
}

// serialEvent method is run automatically by the Processing applet
// whenever the buffer reaches the byte value set in the bufferUntil()
// method in the setup():

void serialEvent(Serial myPort) {
// read the serial buffer:
String myString = myPort.readStringUntil(‘\n’);
// if you got any bytes other than the linefeed:
if (myString != null) {

myString = trim(myString);

// split the string at the commas
// and convert the sections into integers:
int sensors[] = int(split(myString, ‘\t’));

// print out the values you got:
for (int sensorNum = 0; sensorNum < sensors.length; sensorNum++) { print("Sensor " + sensorNum + ": " + sensors[sensorNum] + "\t"); } // add a linefeed after all the sensor values are printed: println(); // Convert integers into behavior. // A change of +/-50 on sensor 1 means a roll forward (down) or backward (up), respectively. Flat is 520. // A change of +/-50 on sensor 2 means a tilt coounter-clockwise or clockwise, respectively. Flat is 505. myKey1=""; myKey2=""; myKey3=""; if (sensors[0] > 570) // rolling forward, so paddle down
{
myKey1 = “d”;
}

if (sensors[0] < 470) // rolling backward, so paddle up { myKey1 = "u"; } if (sensors[1] > 555) // rolling counter-clockwise, so paddle left
{
myKey2 = “l”;
}

if (sensors[1] < 455) // rolling clockwise, so paddle right { myKey2 = "r"; } if (sensors[3] > 0 ) // button pressed
{
myKey3 = “x”;
}

myKeyBuffer = myKey1+myKey2+myKey3;
println(myKeyBuffer);

// If there’s incoming data from the client:

if (myClient.available() > 0) {
// get the data:
data = myClient.readString();
println(data);
}

if (myKeyBuffer != null) {
// send out anything that’s typed:
myClient.write(myKeyBuffer);
}
if (keyPressed) {
// send out anything that’s typed:
myClient.write(key);
}

}

}
[/java]

Pictures vs. words

A word is also a picture of a word

Remember how on March 5th I was supposed to give a presentation in 1′, 2′, 10′, but it got bumped? And then the following week’s class was canceled, and then we had spring break. So it wasn’t until three weeks later, March 26, that I finally got to take my turn squirming at the front of the room. Three extra weeks! So, naturally, I used all that time working on my project, right?

Oh, no, that wouldn’t have been fair. I did revise my slides, but I left it until the last fucking minute, as usual, so as not to have an undue advantage over my classmates. Right. That’s totally why.

What I did do in the interim, however, was stumble across this fab webcast by Nancy Duarte about how to give better presentations:

After hearing her talk, I bought and started reading her book, Slide:ology, which is a more detailed presentation of the same suggestions.

(Here’s another Nancy Duarte webcast, which I haven’t watched yet: Creating Powerful Presentations.)

So between that and taking copious notes on my classmates’ midterm presentations, especially in Wearables, I got a lot of ideas about how I should redo my slides, as well as my overall presentation style. The result is a deck that does not make any sense unless I’m standing there with a remote, explaining it to you (PDF, 1.1 MB)—and using a remote is, I decided after watching a lot of in-class presentations, a good thing to do. I got my Mac remote to turn pages in Acrobat using a program called iRed Lite. I can’t really recommend it, since it stumped me for quite a while the first time I used it, and the next time I tried, a few weeks later, I positively could not figure out how I had ever made it work in the first place. There’s something about the UI that confuses the hell out of me. But it can, theoretically, do the job, and it’s free.

Some other things I learned from watching classmates’ presentations:

  • Proofread, proofread, proofread.
  • Stand while you present, even if you don’t have a remote. Think of someone you know who’s poised and relaxed speaking in front of a group, and then try to channel that person for five minutes. Breathe between sentences. Make eye contact.
  • I really don’t care about the technical side of your project. Don’t tell me what hardware and libraries and so forth are used in it; describe it to me as though I were a normal human being who doesn’t have four Arduini in her apartment right now. Just because I have them doesn’t mean I know how to use them.
  • Those very corporate-looking system diagrams showing how information will flow through your application? They’re completely unintelligible. Skip them.
  • You don’t have to make all your graphics all slick, in Illustrator or Photoshop. Hand-drawn diagrams or sketches can be much more engaging.
  • As early as possible in the presentation, show me some kind of image of what your project will be—or, better yet, the prototype you’re working on—so that I can hold that in my mind as you go into all the background and process and detail. If I don’t know what your project is yet, I probably won’t find the rest of that information interesting. This was true even though I knew perfectly well what my classmates’ projects were. When I watched their presentations, if they didn’t show and describe what they were making early on, I was unable to hold my attention on whatever else they were saying instead. Context.
  • Don’t put a lot of text on the screen. If you’re talking and there’s a whole paragraph on the screen behind you, my attention’s going to be split. And if it turns out that you’re just repeating what that paragraph says, almost word for word, I’ll feel exasperated. People should be listening to you for the words in your presentation, not reading them off the slides.
  • If you don’t have anything sexy to put on a slide for a given portion of your talk, it’s fine to
    1. repeat a previous slide, or
    2. show a slide that contains just one word representing that moment’s topic—“research,” for instance, or “inspiration.” Treat that text as a graphic element—make it big, pay attention to how it looks.
  • Typography!
  • If you have a relevant quotation to share, don’t bury it in a whole long paragraph; give it a slide by itself.
  • Don’t try to cover too much. It’s better to give people a thoughtful, measured thumbnail-presentation of the project and stop talking early enough that there’s time for people to ask questions about the parts that actually interest them than it is to brain-dump every piece of information you have, leaving time for only a few dazed comments from your audience at the end.
  • Videos of a thing working are helpful, but you have to explain what’s going on while it’s playing. This may be a good time to unload some of those boring technical details, while there’s a moving image to spice them up.
  • Proofread, proofread, proofread. If I had a dime for every typo I saw during midterm presentations . . . I offered my services as a proofreader in the Webgrrls-style need/give session we had in 1′ 2′ 10′, but nobody seemed to think they needed such a thing. They are wrong.
  • If you’re going to read some text that appears on a slide, do it slowly, with feeling; don’t just rush through it breathlessly, making it impossible for people to either read the text for themselves or follow what you’re saying. Make it clear that you’re reading what’s on the screen so people don’t have to struggle to figure it out. If you’re not able to introduce the text with something like “I’d just like to read you this quote, which really inspired me . . .” you probably shouldn’t be giving it a slide.

So, here again are the slides I ended up using (PDF, 1.1 MB) for my midterm presentation. I suppose some day maybe I’ll write captions more or less like what I said in front of the class, but in the meantime you can read the old slides if you want to know the gist.

Photo: A WORD IS ALSO A PICTURE OF A WORD by gwalton1; some rights reserved.

Markov bookshelf

best-seller covers

Oh, well. We’re back to kill-me-now territory.

This week’s assignment was

Get some XML from a web service. Extract some interesting information from the XML and use it as input to one of your homework assignments from previous weeks.

You could do this either by piping the output of your XML parsing program to the input of your previously implemented program, or by using a class (e.g., instantiate and use the MarkovChain class).

So I thought, cool, I’ll scramble the New York Times Best Seller titles using their shiny new API. Okay, so, I got an API key and managed to pull in lists of titles using—

[java]import org.dom4j.Document;
import org.dom4j.io.SAXReader;
import org.dom4j.Element;
import java.util.List;

public class BestSeller
{
public static void main(String[] args) throws Exception
{

/* Input should be one of the NY Times Best Seller list categories.
Available categories:
hardcover-fiction
hardcover-nonfiction
hardcover-advice
paperback-nonfiction
paperback-advice
trade-fiction-paperback
picture-books
chapter-books
paperback-books
series-books
mass-market-paperback
*/
String listName = args[0];

SAXReader reader = new SAXReader();
EasyHTTPGet getter = new EasyHTTPGet(
“http://api.nytimes.com/svc/books/v2/lists/” + listName + “.xml?api-key=f25de92cf1d2615621b68d2d31f81b63:4:1703697”
);

Document document = reader.read(getter.responseAsInputStream());
List bookTitle = document.selectNodes(“//results/book/book_details/book_detail/title”);

// If I wanted to scramble the authors, . . .
// List bookAuthor =
// document.selectNodes(“//results/book/book_details/book_detail/author”);

for (Object o: bookTitle)
{
Element elem = (Element)o;
String text = elem.getText();
System.out.println(text);
} // end for
} // end main
} // end class[/java]

I had tried to make an array of category names and then loop through them, but I got lost after the first bit—

[java]import org.dom4j.Document;
import org.dom4j.io.SAXReader;
import org.dom4j.Element;
import java.util.List;

public class BestSellerAll
{
public static void main(String[] args) throws Exception
{

/* There are 11 categories of NY Times Best Seller lists. I want to download all of them, but the Times makes you download them individually.
*/

String [] book_cats = new String [] {
“hardcover-fiction”, “hardcover-nonfiction”, “hardcover-advice”, “paperback-nonfiction”, “paperback-advice”, “trade-fiction-paperback”, “picture-books”, “chapter-books”, “paperback-books”, “series-books”, “mass-market-paperback”};

// String listName = args[0];

SAXReader [] reader = new SAXReader() [];
EasyHTTPGet [] getter = new EasyHTTPGet [];
for (int i = 0; i < 11; i++) { getter[i] = "http://api.nytimes.com/svc/books/v2/lists/" + book_cats[n] + ".xml?api-key=f25de92cf1d2615621b68d2d31f81b63:4:1703697"; } // end for i // I got sadly confused somewhere in this block: Document [] document = new Document []; for (int j = 0; j < 11; j++) { document[j] = reader.read(getter[j].responseAsInputStream()); List bookTitle = document.selectNodes("//results/book/book_details/book_detail/title"); } // end for j // If I wanted to scramble the authors, . . . // List bookAuthor = // document.selectNodes("//results/book/book_details/book_detail/author"); for (Object o: bookTitle) { Element elem = (Element)o; String text = elem.getText(); System.out.println(text); } // end for bookTitle } // end main } // end class[/java] So, semimanually, then, I ran this on one category list at a time and used cat to agglomerate them. So then I had my list of all the current best sellers' titles:

HANDLE WITH CARE
CORSAIR
THE ASSOCIATE
THE HOST
RUN FOR YOUR LIFE
PROMISES IN DEATH
DEAD SILENCE
HEART AND SOUL
ONE DAY AT A TIME
NIGHT AND DAY
THE GUERNSEY LITERARY AND POTATO PEEL PIE SOCIETY
WHITE WITCH, BLACK CURSE
PATHS OF GLORY
TERMINAL FREEZE
FOOL
THE HELP
DON’T LOOK TWICE
FAULT LINE
TRUE COLORS
STORM FROM THE SHADOWS
OUTLIERS
HOUSE OF CARDS
THE YANKEE YEARS
OUT OF CAPTIVITY
DEWEY
THE LOST CITY OF Z
A LION CALLED CHRISTIAN
A BOLD FRESH PIECE OF HUMANITY
MY BOOKY WOOK
THE UNFORGIVING MINUTE
INSIDE THE REVOLUTION
MELTDOWN
ARE YOU THERE, VODKA? IT’S ME, CHELSEA
JESUS, INTERRUPTED
JOKER ONE
NO ANGEL
LORDS OF FINANCE
THE NEXT 100 YEARS
MULTIPLE BLESSINGS
PICKING COTTON
ACT LIKE A LADY, THINK LIKE A MAN
THE LAST LECTURE
THE POWER OF SOUL
THE SECRET
THE ULTRAMIND SOLUTION
FLAT BELLY DIET!
THE GREAT DEPRESSION AHEAD
PEAKS AND VALLEYS
UNCOMMON
THE SURVIVORS CLUB
MAGNIFICENT MIND AT ANY AGE
THE TOTAL MONEY MAKEOVER
EMOTIONAL FREEDOM
THE 4 DAY DIET
FIGHT FOR YOUR MONEY
THREE CUPS OF TEA
THE MIDDLE PLACE
I HOPE THEY SERVE BEER IN HELL
DREAMS FROM MY FATHER
THE TIPPING POINT
EAT, PRAY, LOVE
THE AUDACITY OF HOPE
MY HORIZONTAL LIFE
90 MINUTES IN HEAVEN
TEAM OF RIVALS
SAME KIND OF DIFFERENT AS ME
BLINK
MARLEY & ME
THE FORGOTTEN MAN
THE OMNIVORE’S DILEMMA
THE ZOOKEEPER’S WIFE
BEAUTIFUL BOY
A WHOLE NEW MIND
ANIMAL, VEGETABLE, MIRACLE
INFIDEL
THE LOVE DARE
WHAT TO EXPECT WHEN YOU’RE EXPECTING
EMERGENCY
SUZE ORMAN’S 2009 ACTION PLAN
NATURALLY THIN
TWILIGHT
SKINNY BITCH
THE FIVE LOVE LANGUAGES
THE POWER OF NOW
HAPPY FOR NO REASON
THE PURPOSE-DRIVEN LIFE
A NEW EARTH
THE BIGGEST LOSER 30-DAY JUMP START
HE’S JUST NOT THAT INTO YOU
THE BIGGEST LOSER FAMILY COOKBOOK
THE SHACK
THE READER
FIREFLY LANE
AMERICAN WIFE
SUNDAYS AT TIFFANY’S
PEOPLE OF THE BOOK
A THOUSAND SPLENDID SUNS
TAKE ONE
THE ALCHEMIST
SARAH’S KEY
THE MIRACLE AT SPEEDY MOTORS
THE BRIEF WONDROUS LIFE OF OSCAR WAO
REVOLUTIONARY ROAD
WATER FOR ELEPHANTS
THE WHITE TIGER
STILL ALICE
THE ELEGANCE OF THE HEDGEHOG
LOVING FRANK
THE KITE RUNNER
LUSH LIFE
THE HOUSE IN THE NIGHT
THE COMPOSER IS DEAD
BLUEBERRY GIRL
LISTEN TO THE WIND: THE STORY OF DR. GREG AND “THREE CUPS OF TEA”
LADYBUG GIRL AND BUMBLEBEE BOY
GALLOP!
CAT
SWING!
NAKED MOLE RAT GETS DRESSED
ALL IN A DAY
MILES TO GO
THE GRAVEYARD BOOK
THIRTEEN REASONS WHY
SCAT
THE HUNGER GAMES
FADE
THREE CUPS OF TEA
3 WILLOWS
SEEKERS: GREAT BEAR LAKE
THE MYSTERIOUS BENEDICT SOCIETY AND THE PERILOUS JOURNEY
EVERMORE
THE BOY IN THE STRIPED PAJAMAS
THE BOOK THIEF
THREE CUPS OF TEA: YOUNG READERS EDITION
TWEAK
WICKED: WITCH AND CURSE
CORALINE
THE MYSTERIOUS BENEDICT SOCIETY
THE TALE OF DESPEREAUX
SLAM
THE TWILIGHT SAGA
HOUSE OF NIGHT
DIARY OF A WIMPY KID
THE 39 CLUES
THE CLIQUE
PERCY JACKSON & THE OLYMPIANS
HARRY POTTER
NIGHT WORLD
KISSED BY AN ANGEL
INKHEART
THE WHOLE TRUTH
HOLD TIGHT
BONES
THE GRAND FINALE
PLAGUE SHIP
LOST SOULS
MONTANA CREEDS: DYLAN
DANGER IN A RED DRESS
THE APPEAL
THE MACKADE BROTHERS: RAFE AND JARED
MAVERICK
SMALL FAVOR
ANGELS AND DEMONS
THE READER
SECRETS
FIRST COMES MARRIAGE
CHASING DARKNESS
SHADOW COMMAND
TEMPTATION RIDGE
CONFESSIONS OF A SHOPAHOLIC

And then, all I wanted to fucking do was run the Markov code from week 5 and make some crazy new titles. I had it working earlier in this process, when I was working with just the hardcover fiction list, and came up with these completely uninteresting results:

TERMINAL FREEZE
TERMINAL FREEZE
TERMINAL FREEZE
THE ASSOCIETY
ONE DAY AT A TIME
NIGHT AND SOUL
ONE DAY AT A TIME
FOOL
STORM FROM THE HELP
FOOL
TERMINAL FREEZE
CORSAIR
ONE DAY AT A TIME
TRUE COLORS
FOOL
ONE DAY AT A TIME

Clearly, the set of words was too small to do anything really interesting with, which is when I decided to make one file of all the lists, to get more words. But then . . . I couldn’t get the Markov code to work anymore. Kept getting this stupid error:

java.lang.StringIndexOutOfBoundsException: String index out of range: 4
at java.lang.String.substring(String.java:1765)
at Markov.feedLine(Markov.java:21)
at MarkovFilter.eachLine(MarkovFilter.java:12)
at com.decontextualize.a2z.TextFilter.internalRun(TextFilter.java:326)
at com.decontextualize.a2z.TextFilter.run(TextFilter.java:208)
at MarkovFilter.main(MarkovFilter.java:6)

And it took me one million years to determine that this was because the code was choking on the colon in

LISTEN TO THE WIND: THE STORY OF DR. GREG AND “THREE CUPS OF TEA”

and then the quotation marks, and then something else, and then I still don’t know what. It will not work if I include any lines after “GALLOP.” So, with that frustrating exception noted, here, finally, are the new titles:

I HOPE THE STORM FROM MY FATHERE, VODKA? IT’S ME, CHELSEA
THE FIVE LANE
MY HORIZONTAL LIFE OF DIFFERENT MIND THE LOVE DARE
THE BRIEF WONDROUS LIFE OF THERE, VODKA? IT’S WIFE
INSIDE THE REVOLUTION AHEAD
THE 4 DAY JUMP START
MAGNIFICENT AS ME, CHELSEA
THE ELEGANCE OF SOUL
THE ELEPHANTS
THE UNFORGOTTEN TO THE YANKEE YEARS
THE HEDGEHOG
THE COLORS
THE BOY
PROMISES IN HEAVEN
I HOPE THE TOTAL LIFE OF Z
HE’S DILEMMA
PROMISES IN THE TIPPING MIND SPLENDID SUNS
THE ZOOKEEPER’S JUST NOT THAT TO EXPECT WHEN YOUR LIFE OF NOW
TWILIGHT ANY AGE
A THOUSE OF DIFFERENT MINUTES IN HEAVEN
A BOLD FRESH PIECE OF OSCAR WAO
THE KIND OF HUMANITY
OUT OF GLORY
SAME KITE TIGER
FIGHT ANY AGE
MAGNIFICENT MIND SOUL
SAME KIND OF HUMANITY
THE FIVE LANGUAGES
THE MIDDLE WITH CARDS
TERMINAL FRESH PIE SOCIATE
90 MINUTES IN DEAD SILENCE
HE’S 2009 ACTIONARY AND SOLUTIONAL FRESH PIECE OF DIFFERENT MIND SOUL
NIGHT FOR ELEGANCE OF THERE, VODKA? IT’S WIFE
STORM FROM THERE, VODKA? IT’S JUST NOT THAT INTO YOUR LIFE OF THE LOVE DAY JUMP START
THE NIGHT ANY AGE

Comparalator

date merchant

As you may recall, for my midterm project, I got stumped on several seemingly simple tasks. One of those—the most important, since upon it depends my semester-long assignment for Mainstreaming Information—was figuring out a way to compare one list of words to another and pull out the words that were unique to one of those lists. In my head, I can see very easily how this would be done. Given my special way of haphazardly flailing through code, however, I just couldn’t get it to work.

Until today!

In fiddling with the Bayesian comparison code for this week’s homework, I finally pulled out a list of unique words. Of course, this is a completely perverse misuse of that code—like using a steamroller to kill a pillbug—but as long as it works, I don’t fucking care.

So, here’s what I did. In BayesClassifier.java, I replaced the last two for loops with the following:

[java]for (String word: uniqueWords)
{
for (BayesCategory bcat: categories)
{
double wordProb = bcat.relevance(word, categories);
if (wordProb < 1) { println(word); } else {} } // end for bcat } // end for word for (BayesCategory bcat: categories) { double score = bcat.score(uniqueWords, categoryWordTotal); println("---The following words were not found in " + bcat.getName()); } // end for bcat[/java] And in BayesCategory.java I replaced the percentage and relevance blocks with [java] public double percentage(String word) { if (count.containsKey(word)) { return count.get(word); } // end if else { return 0.001; } // end else } // end percentage public double relevance(String word, ArrayList categories)
{
double percentageSum = 0;
for (BayesCategory bcat: categories)
{
percentageSum += bcat.percentage(word);
} // end for bcat
return percentage(word);
} // end relevance[/java]

So now, if I run the command

$ java BayesClassifier A2_unique.txt < B1_unique.txt | sort >results.txt

I get a list of words that are in B1_unique.txt (The Masada Scroll by Paul Block and Robert Vaughan, 2007) but not in A2_unique.txt (Zuleika Dobson or, An Oxford Love Story by Max Beerbohm, 1911). For example,

Akbar, Allah, Allahu, Apostolic, Ariminum, Arkadiane, Asmodeus, Astaroth, Barabbas, Beelzebub, Bellarmino, Blavatsky, Brandeis, Breviary, Byzantine, Caiaphas, Calpurnius, Catacombs, Charlemagne, Clambering, DNA, Diavolo, Franciscan, Freemasons, GPS, Gymnasium, Haddad, Hades, IDs, IRA, Jettisoning, Kathleen, Lefkovitz, MD, MRI, Masada, Masonic, Muhammad, Muhammadan, Nazarene, Nazareth, Olympics, Orthodoxy, Palatine, Palazzi, Palestine, Palestinian, Palestinians, Petrovna, Pleasant, Plenty, Plunge, Pocketing, Pontiff, Pontifical, Pontius, Praetorian, Prissy, Professors, Protestants, Rasulullaah, Ratsach, Revving, Rosicrucians, Satan, Scrolls, Seder, Shakespeare, Syracuse, Tacitus, Theosophical, Torah, Trastevere, Turkish, USB, Uzi, VAIO, VCR, Yeah, Yechida, Yeetgadal, Yiddish, adrenalin, agita, airliner, airport, ankh, awesome, bitch, bomb, bookstores, braked, breastplate, briefcase, broadsword, broiler, brotherhood, bulrushes, cellular, checkpoint, chuckling, chutzpah, combatant, computer, dashboard, database, departmental, desktop, divorce, dysentery, electricity, enabling, entrepreneurs, firearms, firestorm, fishtailed, flagon, forensics, goatskin, groggily, gunfire, gunman, gunshots, handbag, handball, handbrake, handgun, helicopter, helmets, highwaymen, hijinks, homeland, homeless, homespun, hometown, innkeeper, internship, journalist, kebob, kidnappers, kilometers, lab, laptop, lyre, mawkish, monitor, muezzin, nickname, nightfall, nonbeliever, northeaster, notebook, notepad, notepaper, numerology, paganism, password, pastries, phone, photo, photocopies, photocopy, photograph, photos, pig, pigeons, pistol, playback, police, quintessentially, recycles, redialed, roadblock, roadway, sandwich, screensaver, site, sites, submachine, superheating, synagogue, taped, taxi, terrorism, terrorist, terrorists, thousandfold, thrashing, toga, tortured, trigonometry, universe, unto, vegetables, vehicles, video, videotape, vinegar, violence, warehouses, waterfall, welfare, wholeheartedly, whoosh, whore, windshield, worker, workstation, worldwide, yardstick, yarmulkes, yeetkadash, zooming

And if I run the comparison in the opposite direction, I come up with words such as

Abernethy, Abiding, Abimelech, Abyssinian, Academically, Academy, Accidents, Achillem, Adam, Adieu, Admirably, Age, Agency, Agents, Alas, Albert, Alighting, America, Atlantic, Australia, Balliol, Baron, Baronet, Britannia, Broadway, Brobdingnagian, Colonials, Cossacks, Crimea, Devon, Dewlap, Duchess, Duke, Dukedom, Earl, Edwardian, Egyptians, Elizabethan, Englishmen, Englishwoman, Europe, Holbein, Ireland, Iscariot, Isis, Japanese, Kaiser, Liberals, London, Madrid, Meistersinger, Messrs, Monsieur, Napoleon, Novalis, Papist, Parnassus, President, Prince, Professor, Prussians, Romanoff, Segregate, Slavery, Socrates, Switzerland, Tzar, Victoria, Wagnerian, Waterloo, Whithersoever, Zeus, absinthes, acolyte, adventures, affrights, affront, afire, afoot, aforesaid, aggravated, album, analogy, anarchy, ankle, ape, aright, aristocracy, ataraxy, automatically, avalanche, avow, balustrade, bandboxes, bank, beastliest, beau, beauteous, billiards, biography, bodyguard, bosky, boyish, broadcast, bruited, bulldog, businesslike, bustle, calorific, casuistry, catkins, chaperons, chidden, cigarettes, clergyman, cloven, comet, compeers, coquetry, cricket, crinolines, custard, dandiacal, dapperest, decanter, devil, dialogue, diet, dipsomaniacal, disemboldened, disinfatuate, drunken, ebullitions, equipage, exigent, eyelashes, eyelids, farthingales, female, femininity, fishwife, fob, forefather, forerunners, freemasonry, furbelows, gallimaufry, goodlier, gooseberry, gorgeous, gypsy, haberdasher, halfpence, handicapped, handicraft, handiwork, handwriting, hearthrug, helpless, hip, hireling, honeymoon, housemaid, housework, hoyden, hussy, idiotic, impertinent, impudence, inasmuch, incognisant, insipid, insolence, insouciance, item, keyboard, landau, legerdemain, loathsome, luck, maid, maidens, manhood, manumission, matador, maunderers, model, mushroom, nasty, newspaper, noodle, nosegay, novel, oarsmen, omnisubjugant, ostler, otiose, parasol, pinafore, poetry, poltroonery, postprandially, prank, prestidigitators, propinquity, queer, romance, sackcloth, salad, sardonic, saucy, schoolmaster, seraglio, sex, skimpy, skirt, snuff, socialistic, streetsters, surcease, surcoat, swooned, teens, telegram, telegraphs, thistledown, thither, thou, threepenny, tomboyish, toys, tradesmen, treacle, ugly, uncouthly, unvexed, vassalage, waylay, welter, wigwam, witchery, withal, woe, woebegone, womanly, womenfolk, wonderfully, wonderingly, wretchedness, wrought, yacht, yesternight, zounds

Exciting!

Cookalator

Five eggs

For our Context Free assignment, I chose to make a recipe generator. Mmm, don’t you want to cook this up right now?

  1. Toss 1/3 cup thinly sliced baking soda and 1 quart egg yolks with a whisk until just blended.
  2. Knead 5 cups cubed light corn syrup with a wooden spoon until golden brown.
  3. In a cast iron Dutch oven, pour 1/4 pinch egg yolks, 1/4 cup whole milk, and 2 pounds sifted egg.
  4. Simmer 3 pounds light corn syrup with 1 cup thinly sliced brown sugar and 2 teaspoons sifted heavy cream.
  5. In a small saucepan, boil 3 ounces thinly sliced egg, 4 cups peeled water, and 3/4 tablespoon water until incorporated.
  6. Whisk together 1 pound ginger and 2 cups candied egg whites until golden brown.
  7. Beat 2 quarts marzipan with a wooden spoon until the pieces are pea-sized.
  8. Grate 1/2 teaspoon sifted unsweetened cocoa powder with 2 quarts baking powder and 3/4 ounce ginger.
  9. Beat 5 pounds thinly sliced buttermilk, 5 quarts sifted whole milk, and 4 tablespoons thinly sliced egg with a wooden spoon until slightly warm.
  10. In a large bowl, boil 5 cups candied kosher salt, 2 cups diced lemon zest, and 1/2 cup sifted buttermilk until incorporated.
  11. In a shallow pan, simmer 5 tablespoons thinly sliced ginger until golden brown.
  12. Beat 2/3 teaspoon brown sugar, 2 ounces diced egg yolks, and 3 teaspoons unsalted butter with 3 teaspoons light corn syrup, 1/2 tablespoon thoroughly washed lemon zest, and 3/4 quart peeled whole milk.
  13. Brush 2 tablespoons grated kosher salt, 2/3 tablespoon sugar, and 4 pounds diced baking powder until it forms a thick syrup.

Here’s the grammar I used:

[java]# procedures
S -> In a V Action IP with a Utensil until When
S -> In a V Action IP until When
S -> In a V Action IP .
S -> Action IP with IP .
S -> Action IP with a Utensil until When
S -> Action IP until When
IP -> IN
IP -> IN and IN
IP -> IN , IN , and IN
IN -> SQuantity SUnit Prep Ingredient
IN -> SQuantity SUnit Ingredient
IN -> PQuantity PUnit Prep Ingredient
IN -> PQuantity PUnit Ingredient
V -> Size Quality Vessel
V -> Size Vessel
V -> Quality Vessel
V -> Vessel

# components
SQuantity -> 1/4 | 1/2 | 1/3 | 3/4 | 2/3 | 1
PQuantity -> 2 | 3 | 4 | 5
SUnit -> pinch | teaspoon | tablespoon | ounce | cup | pound | quart
PUnit -> pinches | teaspoons | tablespoons | ounces | cups | pounds | quarts
Ingredient -> all-purpose flour | water | egg whites | egg yolks | heavy cream | whole milk | almond paste | marzipan | sugar | baking powder | baking soda | kosher salt | ginger | unsalted butter | egg | buttermilk | lemon zest | light corn syrup | bittersweet chocolate | unsweetened cocoa powder | brown sugar
Prep -> grated | cubed | chilled | sifted | diced | candied | thoroughly washed | peeled | thinly sliced | melted
Vessel -> bowl, | saucepan, | pot, | Dutch oven, | pan, | ramekin, | skillet,
Quality -> separate | airtight | cast iron | heatproof | nonstick | heavy-bottomed | shallow | buttered
Size -> large | small | medium
Action -> combine | whisk together | knead | brush | sprinkle | pour | stir | beat | boil | simmer | saute | brown | grate | mash | toss | blend
Utensil -> wooden spoon | whisk
When -> combined. | the pieces are pea-sized. | incorporated. | just blended. | it forms a thick syrup. | translucent. | golden brown. | slightly warm. | completely cooled.[/java]

Yummers!

Kill me now.

Stabby McKnife

Oh, honestly.

For once I actually set out to be a slacker on the homework. The assignment began,

Modify, augment, or replace one of the in-class examples. A few ideas, in order of increasing complexity:

  • Make Unique.java insensitive to case (i.e., “Foo” and “foo” should not count as different words).
  • Modify WordCount.java to count something other than just words (e.g., particular characters, bigrams, co-occurrences of words, etc.). . . .

So I thought, “Today I feel like doing the easy thing. I’ll just take that first option.”

Yeah, right. Many hours later, after trying several extremely complicated methods of doing this really fucking simple thing, I finally found the rat-simple method that I’d been looking for all along and had all but given up hope of. Goddamnit.

The original code was this:

[java]import java.util.HashSet;
import com.decontextualize.a2z.TextFilter;

public class Unique extends TextFilter {
public static void main(String[] args) {
new Unique().run();
}

private HashSet uniqueWords = new HashSet();

public void eachLine(String line) {
String[] tokens = line.split(“\\W+”);
for (String t: tokens) {
uniqueWords.add(t);
}
}

public void end() {
for (String word: uniqueWords) {
println(word);
}
}
}[/java]

and what I came up with after way too much beating my head against the desk is this:

[java]import java.util.HashSet;
import java.util.regex.*;
import com.decontextualize.a2z.TextFilter;

public class UniqueCI extends TextFilter
{
public static void main(String[] args)
{
new UniqueCI().run();
} // end main

private HashSet uniqueWords = new HashSet();
private HashSet lowercaseWords = new HashSet();

public void eachLine(String line)
{
String[] tokens = line.split(“\\W+”);
for (String t: tokens)
{
// If hashset that’s all lowercased contains t all lowercased, then don’t add anything.

String tLower = t.toLowerCase();

if (lowercaseWords != null && lowercaseWords.contains(tLower))
{
} // end if
else if (lowercaseWords != null)
{
uniqueWords.add(t);
lowercaseWords.add(tLower);
} // end else
} // end for
} // end eachLine

public void end()
{
for (String word: uniqueWords) {
println(word);
} // end for
} // end end
} // end class UniqueCI[/java]

If you put this in,

It is a truth universally acknowledged, that a single man in possession of a large fortune must be in want of a wife.
It Is A Truth Universally Acknowledged, That A Single Man In Possession Of A Large Fortune Must Be In Want Of A Wife.

you get this out:

of
possession
wife
truth
be
large
It
fortune
universally
single
that
acknowledged
man
a
must
want
is
in

Big whoop. I wish I could say I learned a lot from this, but I think all I learned is that I’m much more lost than I thought I was.

Photo: The Downward Knife by Jill Greenseth; some rights reserved.

“Have you seen my wig around?”

Jane Says

This week’s A2Z assignment was as follows:

Make a program that creatively transforms or performs analysis on a text using regular expressions. The program should take its input from the keyboard and send its to the screen (or redirect to/from a file). Your program might (a) filter lines from the input, based on whether they match a pattern; (b) match and display certain portions of each line; (c) replace certain portions of each line with new text; or (d) any combination of the above.

Sample ideas: Replace all words in a text of a certain length with a random word; find telephone numbers or e-mail addresses in a text; locate words within a word list that will have a certain score in Scrabble; etc.

Bonus challenge 1: Use one or more features of regular expression syntax that we didn’t discuss in class. Reference here.

Bonus challenge 2: Use one or more features of the Pattern or Matcher class that we didn’t discuss in class. Of particular interest: regex flags (CASE_INSENSITIVE, MULTILINE), “back references” in replaceAll. Matcher class reference here.

So, what I made is a program that tries to find the proper names in the input text (my preferred input being the first scene of Pride and Prejudice) and replace them with names of people in our class. For my purposes, a proper name is any capitalized word that (a) follows an honorific, such as Mr., Mrs., Sir, Lady, or Miss, or (b) does not immediately follow a carriage return or chunk of terminal punctuation (i.e., a period, exclamation point, or question mark, with or without a closing quotation mark thereafter), and (c) is neither a day of the week, a month of the year, nor the name of a holiday (though the only holiday it’s really looking for is Michaelmas, as that’s what appears in my P&P extract).

I tried for hours to do this in a compact way, by looking for the absence of certain words or characters (terminal punctuation, honorifics, days of the week, holidays) combined with the presence of other patterns, but it just would not fly. So the result requires a lot of intermediate steps, to avoid changing words that have been identified as not likely to be names. In a vain attempt to make testing my regular expressions quicker, I worked them out in BBEdit first, using the grep option in the search and replace panel. Saved me from having to recompile the thing fifty thousand times. And the expressions worked in BBEdit, for the most part. They do not work so well translated into Java, unfortunately—the success rate at finding names is much lower, and after ten straight hours, I just didn’t have the patience to troubleshoot it any more. But these glitches just make the results more funny, which is, of course, the point.

So, here is the code:

[java]import java.util.regex.*;
import com.decontextualize.a2z.TextFilter;

public class RegexNames extends TextFilter
{
public static void main(String[] args)
{
new RegexNames().run();
} // end main(String[] args)

private String search1 = “(Mr\\.|Mrs\\.|Lord|Lady|Sir) ([A-Z]\\w+)”;
private String replace1 = “##NAME##”;

private String search2 = “(\\.” |\\?” |!” |\\. |\\? |! |\\r|\\r“)([A-Z]\\w+)”;

private String search3 = “( |“|\\r)(Mr\\.|Mrs\\.|Lord|Lady|Sir|Miss|Monday|Tuesday|Wednesday|Friday|Saturday|Sunday|January|February|March|April|May|June|July|August|September|October|November|December|Michaelmas)”;

private String search4 = “( |“)([A-Z][a-z]+)”;

private String [] class_names = new String [] {
“Adam”, “Alejandro”, “Andrew”, “Bryan”, “Caroline”, “Dimitris”, “Jonathan”, “Joseph”, “Martin”, “Michael”, “Ozge”, “Sanjay”, “Steven” };
public void begin()
{
println(“* * *”);
}

public void eachLine(String line)
{
String line_new;

Pattern p1 = Pattern.compile(search1);
Matcher m1 = p1.matcher(line);
if (m1.find())
{
line = line.replaceAll(m1.group(2), replace1);
}

line_new = line;

Pattern p2 = Pattern.compile(search2);
Matcher m2 = p2.matcher(line_new);
if (m2.find())
{
line_new = line_new.replaceAll(m2.group(2), “##” + m2.group(2) + “##”);
}

Pattern p3 = Pattern.compile(search3);
Matcher m3 = p3.matcher(line_new);
if (m3.find())
{
line_new = line_new.replaceAll(m3.group(2), “##” + m3.group(2) + “##”);
}

Pattern p4 = Pattern.compile(search4);
Matcher m4 = p4.matcher(line_new);
if (m4.find())
{
line_new = line_new.replaceAll(m4.group(2), “##NAME##”);
}

line_new = line_new.replace( “##NAME##”, class_names[(int)(Math.random() * 13)] );

line_new = line_new.replace( “##”, “” );

println(“\t” + line_new);
} // end eachLine(String line)

public void end()
{
println(“* * *”);
}

} // end RegexNames extends TextFilter[/java]

And here is the output (you can find the original text at Project Gutenberg):

* * *
     It is a truth universally acknowledged, that a single man in possession of a large fortune must be in want of a wife.
     However little known the feelings or views of such a man may be on his first entering a neighbourhood, this truth is so well fixed in the minds of the surrounding families, that he is considered the rightful property of someone or other of their daughters.
     “Adam dear Mr. Adam,” said his lady to him one day, “have you heard that Netherfield Park is let at last?”
     Mr. Bryan replied that he had not.
     “Steven it is, returned she; ”for Mrs. Steven has just been here, and she told me all about it.
     Mr. Michael made no answer.
     “Dimitris you not want to know who has taken it?” cried his wife impatiently.
     “YOU want to tell me, and I have no objection to hearing it.”
     This was invitation enough.
     “Steven, my dear, you must know, Mrs. Steven says that Netherfield is taken by a young man of large fortune from the north of England; that he came down on Monday in a chaise and four to see the place, and was so much delighted with it, that he agreed with Mr. Morris immediately; that he is to take possession before Michaelmas, and some of his servants are to be in the house by the end of next week.”
     “Joseph is his name?”
     “Adam.”
     “Dimitris he married or single?”
     “Bryan! Single, my dear, to be sure! A single man of large fortune; four or five thousand a year. What a fine thing for our girls!”
     “How so? How can it affect them?”
     “Bryan dear Mr. Bryan,” replied his wife, “how can you be so tiresome! You must know that I am thinking of his marrying one of them.”
     “Ozge that his design in settling here?”
     “Caroline! Nonsense, how can you talk so! But it is very likely that he MAY fall in love with one of them, and therefore you must visit him as soon as he comes.”
     “I see no occasion for that. You and the girls may go, or you may send them by themselves, which perhaps will be still better, for as you are as handsome as any of them, Mr. Michael may like you the best of the party.”
     “Michael dear, you flatter me. I certainly HAVE had my share of beauty, but I do not pretend to be anything extraordinary now. When a woman has five grown-up daughters, she ought to give over thinking of her own beauty.”
     “Jonathan such cases, a woman has not often much beauty to think of.”
     “Michael, my dear, you must indeed go and see Mr. Michael when he comes into the neighbourhood.”
     “Steven is more than I engage for, I assure you.”
     “Jonathan consider your daughters. Only think what an establishment it would be for one of them. Sir Jonathan and Lady Lucas are determined to go, merely on that account, for in general, you know, they visit no newcomers. Indeed you must go, for it will be impossible for US to visit him if you do not.”
     “Sanjay are over-scrupulous, surely. I dare say Mr. Sanjay will be very glad to see you; and I will send a few lines by you to assure him of my hearty consent to his marrying whichever he chooses of the girls; though I must throw in a good word for my little Lizzy.”
     “I desire you will do no such thing. Lizzy is not a bit better than the others; and I am sure she is not half so handsome as Michael, nor half so good-humoured as Lydia. But you are always giving HER the preference.”
     “Andrew have none of them much to recommend them,” replied he; “they are all silly and ignorant like other girls; but Lizzy has something more of quickness than her sisters.”
     “Mr. Bryan, how CAN you abuse your own children in such a way? You take delight in vexing me. You have no compassion for my poor nerves.”
     “Caroline mistake me, my dear. I have a high respect for your nerves. They are my old friends. I have heard you mention them with consideration these last twenty years at least.”
     Mr. Dimitris was so odd a mixture of quick parts, sarcastic humour, reserve, and caprice, that the experience of three-and- twenty years had been insufficient to make his wife understand his character. HER mind was less difficult to develop. Dimitris was a woman of mean understanding, little information, and uncertain temper. When she was discontented, she fancied herself nervous. The business of her life was to get her daughters married; its solace was visiting and news.
* * *

Studio interface ideas

materials

This week’s assignment for 1′, 2′, 10′ was a longie, and it stumped the hell out of me and, apparently, a couple of other people:

Like I’ve said in class before, the game changer for the computer industry was Apple’s innovation of WIMP (windows, icons, menus, and pointing devices) – Apple’s interface became popular because it was immediately intuitive and simple to use. People recognized a ‘desktop’ as a, well, a ‘desktop’. Folders as folders. A trash can as a trash can. etc. This hasn’t changed in 25 years and there are currently discussions to see if it should. So, our homework is to explore, research and document 5 new User Interface experiences that we could apply to a computer, from the real world. Examples that exist today and are changing this model are the multi touch ‘stretch’ for enlarging images, a play button for video, a trash can for trash etc.

We should think about new ways to say things in an online environment. How do you tell someone they are near the end of an article, in a non-digital setting you would could glance to the end, but digitally you have numbers like PAGE 1 of 5 etc. Is there a better way to make the show this? What about rethinking the desktop? Could it be multi-dimential? Maybe it becomes 3D? Maybe it becomes like the iPhone and it’s just icons of apps and only one thing can be open at a time… maybe not. The folder concept worked for small pieces of data, but now it’s not a great interface, the more data we create, the more folders we need and sub folders etc. What about a music player UI? Or a book interface? IMPORTANT: There are two things to think about here, there is the design / interface, and then there is the modality. An example is. The trashcan represents the Interface, but dropping trash into it represents the action.

Start to think about ways that we can make the exprience better than exists today. Please come with 5 examples of these and a brief description of how they would work. And try to push the boundaries. You can write them out as a description, you can sketch them out on your computer. You can use crayolas, pencils, markers or candle wax, but make sure you put effort into showing how it will work. And bring your research to discuss in class.

I scribbled down a bunch of lists of real-life contexts that might supply metaphors for a computer interface—kitchen, farmhouse, library, city—all of which seemed ridiculous. What’s wrong with the desktop metaphor that we have? Besides, you know, the fact that I’ve never been much of a desk-user, and why are those things called “windows,” and what’s with “icons,” and so forth. If you were to make a user interface based on where and how I actually work, it would have to include elements such as “couch,” “pile,” “bookalanche,” and “crumbs,” and the OS would have to be called something like “putter” or “noodle.” Probably not so useful to other people.

So, instead, I was thinking about what kind of interface might make more sense to my mom, who has been using computers for about twenty-five years and Macs for almost ten, and who does not understand what or where her “desktop” is, nor the difference between an application, a window, and the operating system itself. She’s an artist, so I thought a studio metaphor might make more sense. But also, inverting the nesting metaphor of the whole OS might help. That is, why does she have to know which application to use, and then open a file within that? Why can’t she just have stuff that she’s working on, and then use tools to modify it? So the “applications” become “tools,” and the “document” becomes a “work” made of materials and a process.

When you want to make a new work, you go to the materials shelf and choose a basic substance to start with—2D (e.g., paper, canvas) or 3D (a blob)? You drag it onto the easel, of which you can have more than one. Then you can select some properties of that material. Size? Color? How rigid or stretchy do you want it to be? How translucent? How smooth? Many of these would probably best be controlled using slider, though for something like texture, you’d probably want a swatch.

Choose a tool, such as a brush or roller, or type from a California job case; assign a color; and and start doing stuff to your material. To pick a color, you would have a palette and a mixing area, so that you could mix or dilute colors. The resulting mixtures could be added to a global palette or discarded. Use your 3D mouse to shape it. Pick another material off the shelf and attach it. Choose an (optional) adhesive (which could include staples, sewing) and the attachment point or surface. How hard are they pressed together—like, does one dent the other? You can type on any surface of an object. You can drag one material against another to transfer properties such as color or texture. You can fold the material by marking a scoring line and dragging one side over the other. You can flip a piece of 2D material over and work on the back.

When you’re done with a work, you can stick it in a drawer. Each work would be stored as a recording of its process of construction. At any time, you could select an existing work from a drawer and use a slider to move back along a timeline, if you want to undo something. To repeat an operation, you could select a segment of the timeline, copy, and paste it to the same work or to any other work.