Query writing: A Template for Query Letters

Posted in for writers, Writing
Query writing template for fiction
A Query Letter Template: Introduction

I can’t believe I’m writing a blog post about querying. Seriously? There are 7.8 ba-tillion posts out there that boast of being the “definitive guide to querying agents.” Why in Potter’s scar would I add to the refuse of rhetoric???

Because (and I seriously don’t understand why my elementary school teachers taught me never to start a sentence with “because”….), despite reading sooooo many blog posts and consuming soooooo many books and having my own queries critiqued soooo many times…

I. Still. Didn’t. Get. It.

Now, it’s entirely possible that all those emptamafillion articles were saying exactly what needed to be said and I just didn’t get it. (That wouldn’t be unheard of…don’t let the Ph.D. fool ya….I’m pretty dense). But I’m going to offer not just an explanation, but also a method for doing it–one that builds the query letter in stages. One that begins with a template!!! Seriously. Like, fer realz. You can’t get simpler than that–a query letter template for literary agents!

So….are ya’ll ready to git-r-done?

The Bones (A Query Letter Template)

I make a promise to you. By the end of today, you will NOT have a query ready. Ha! How’s that for honesty? Even if you plow through all these lessons, you aint there…na uh. There’s still critique groups and revisions and more critiques. BUT, we’ll get ya started. All you have to do is fill out the query letter template below!

(Insert character name) is a (insert character trait) who (tell us about how “normal life.”) Yet when (give inciting incident) happens, (state something that is thrown out of balance).

Now, (state character name) is forced to (state what the central goal of the story is). As (s)he attempts to (name things the character does to accomplish said goal), (state what obstacles are encountered).

Forced to choose between (state one sucky choice) and (state the other sucky choice), (state character’s name) must decide what matters more–(consequence of choice #1) or (consequence of choice #2).

Example of using the query letter template

Let’s do an example with a story with which we’re all familiar. How about Billy Goats Gruff? We’ll have to embellish some of the details, but this outta be fun!

Tommy the goat is the youngest of two older brothers who all enjoy feasting on grass in the meadow. Yet when Bibbledy-Basty McFladigan, the neighborhood troll sets their meadow on fire, Tommy and his two brothers’ very existence is threatened.

Now, Tommy and his brothers embark on a journey across the bridge that will lead them to another pasture. As they attempt to cross, Bibbledy-Basty threatens to eat them. Forced to choose between certain death by starvation and probable death by troll, Tommy must decide whether to face his fears or starve.

It’s certainly not my best writing, nor will it be your best. That’s okay. At this point, it should suck! You have the bones of a query letter–a corpse, if you will. An ugly corpse (then again, what corpse isn’t?). But this corpse will travel backwards in time toward vitality, Benjamin Button style.

After writing the query, I want you to do one more thing–read it to your friends, family members, enemies, and sentient plants (or anybody who hasn’t read the book) and ask them one question, “Is the choice (s)he’s forced to make a difficult one?”

I say this because so many queries I’ve read look like this, “Amy’s father is a jerk. When she meets Al, she’s in love. Yet Father hates Al. Now she must choose between love and family loyalty.” Ummmm….duh? Her father’s a jerk. Why wouldn’t she choose Al? So, if the choice isn’t difficult, the stakes aren’t high enough (in other words, the cost associated with one choice over the other are not large enough).

Got it?

Tune in next time, when we add some flesh to these bones.

The clear() function

Posted in Statistics
Introduction

Here was a common issue I had in grad school. I’d sit hunched before my computer, eyes twitching from looking at the screen too long, toilets flushing in the bathroom next door to my office. And to top it off, the AC’s broke, so I’m sweating like a swimming pool. And my R program JUST. WON’T. WORK!

Debug, debug, debug. My stomach growls, protesting another missed meal. My wife is texting, asking when I’m coming home. “As soon as I get this program working,” I say. “Kids are screaming, hurry up,” she says.

And I’m about to scream too. But then…the moment comes. I make a change and everything works. Wahoo!

Or is it wahoo?

The next day, I return to the same humid office to find that the program no longer works.

But-but-but-but…it worked yesterday!!!! How could it work yesterday, and not today? That lying sack of computer code!

The Problem

Let’s say you’ve got the following code

d = rnorm(100) #### insert gobbledy goop that shouldn't change d### #### and now we return to the bottom of the page### mean(d) ### should be zero, eh? ####

But mean(d) says 1000! Say, what??? How could that be? Well, it seems you’ve forgotten one little thing. While going to a source file to edit a function (or something like that), you accidentally run this little line of code:

d = rnorm(100, mean=1000)

but forgot. So R originally assigned d a bunch of random numbers with a mean of zero, but later replaced it with a new set of random numbers with a mean of 1000. So, when you try to calculate the mean, it’s not going to remember what you originally assigned to it, but it’s going to remember the most recent assignment.

How often does it happen? Not often, but often enough that it’s a big hassle (especially if I’m sourcing functions and whatnot).

The Solution

To solve this problem, I used to include one line of code at the beginning of every R document

rm(list=ls())

That clears R’s memory from the get-go, that way any debugging will be entirely contained within your current document. It’s a clear slate. A fresh start. Turning over a new leaf. Like January 1st or the end of an AA meeting–past sins forgotten, nuttin’ but clean programming ahead.

But…I got sick of typing all that in just to wipe R’s memory. So I built a function called clear(). The Gildroy Lockehart of programming, that function.

How to use it

The easiest way is to just wipe everything

clear()

Or you can remove only objects named dobby

clear("dobby", keep=F)

Or you can remove all objects but dobby (since, you know, dobby’s pretty much the man):

clear("dobby", keep=T)

Neato, eh?

Practice

Posted in Introduction to R, Statistics
Practice

For each of the questions, remember that you can always look at the documentation to find out more information about the functions. Also, I recognize that it would be nearly impossible to determine how to do this practice with only the information I’ve provided. Consequently, I recommend becoming quite familiar with Google.

First, you’ll need to download the following files:

avdata

tdata

zdata

1. Using the dataset titled zdata.csv, do a z-test to determine whether the sample data differs from the population mean. Assume mu=100 and sigma=15. Be sure to report the z_obt and p_obt as well as to state the conclusion.

2. Using the dataset called tdata.csv to conduct a two independent sample t-test.

3. Using that same dataset, conduct a two dependent sample t-test

4. Using the dataset avdata.csv, conduct an ANOVA to determine whether the three groups differ. Be sure to report the F statistic and a p value.

R Packages

Posted in Introduction to R, Statistics
Packages

Perhaps the coolest thing about R is the packages. So what are packages? To understand, let’s suppose your name is Greg and you start using R because it’s the cool thing to do. As you begin to test its functionality, you’re quite surprised that, in order to do a simple Z-test, you have to do a lot of programming:

#### here's my sample data--Greg x = c(7,11,9,12,13,8,12,12,10,9) #### this is the value of mu. #### Is my sample different from 7?--Greg mu = 7 sigma = 2 xbar = mean(x) ###### compute the z score --Greg z.score = (xbar-mu)/(sigma/sqrt(length(x))) ##### look up p value p.value = pnorm(z.score, lower.tail=FALSE) ##### make a conclusion if (p.value < .05) { cat("Reject the Null") }

Notice how Greg has been wise with his generous use of comments (recall comments are noted by anything that follows one or more pound signs). If Greg runs the code, he gets the following:

#### here's my sample data--Greg x = c(7,11,9,12,13,8,12,12,10,9) #### this is the value of mu/stdev. #### Is my sample different from 7?--Greg mu = 7 stdev = 2 xbar = mean(x) ###### compute the z score --Greg z.score = (xbar-mu)/(stdev/sqrt(length(x))) ##### look up p value p.value = pnorm(z.score, lower.tail=FALSE) ##### make a conclusion if (p.value < .05) { cat("Reject the Null") } else { cat("Fail to Reject the Null") } ## Reject the Null

But that seems like a whole lotta work just to make a simple conclusion. He decides to write his own function (which we’ll get to later) so that he doesn’t have to write so many lines of code every time he wants to do a z-test. Now, all Greg has to do is two lines of code:

## Loading required package: TeachingDemos x = c(7,11,9,12,13,8,12,12,10,9) z.test(x, mu=9, stdev=2) ## ## One Sample z-test ## ## data: x ## z = 2.055, n = 10.000, Std. Dev. = 2.000, Std. Dev. of the sample ## mean = 0.632, p-value = 0.03983 ## alternative hypothesis: true mean is not equal to 9 ## 95 percent confidence interval: ## 9.06 11.54 ## sample estimates: ## mean of x ## 10.3

(Note: many other features have been added beyond a simple “reject the null.”) After writing the function, he’s quite proud of it and thinks, “I can’t be the first person who wanted to do a z-test in R. There’s got to be others out there. I bet they’d appreciate it if I made my package available to them!”

So Greg decides to make his z score function available online. When someone makes their function (or set of functions) available through R’s website, it is called a package. The cool thing about packages is that there are thousands upon thousands of R users, many of which write packages and publish them online. That means that R has a lot of added functionality that it otherwise would not because somebody somewhere decided to publish a package.

Installing a Package

As I said, there are lots of R packages available online. But the good news is that you don’t have to go searching for them to download them. Instead, you can download them right from R’s interface. Let’s go ahead and download a z score function from a package called . The author of this package is Greg Snow (no relation to our fictitious Greg of earlier). To download the package type the following

install.packages("TeachingDemos")

A new window will pop up asking you to pick a repository. A “repository” is just a fancy word for “a place to download the package from.” Then it will download the package and make it available for you to call. To call the package (i.e., to make it available for use), you simply type

require(TeachingDemos)

Now you’re ready to use the z.test function by Greg Snow. Thanks Greg!

Next, Practice using R.