Variable: something about a case that can change from one case to the next, where a case is one thing you study, such as one chat message. Example: the game column says Fortnite for one stream and Just Chatting for another.
Independent variable (IV): the proposed cause, or the predictor you measure. Example: stream type, gaming or non-gaming.
Dependent variable (DV): the outcome you think the IV changes. Example: the share of chat messages aimed at the streamer.
Coding one message by hand takes about forty-five seconds
The 35,267 messages in the example working sample would take over four hundred hours
The full 2018 collection would outlast your degree
Census: coding every case in the population, which works only when the population is small. Example: the example stream table ships whole, about 32,000 snapshots of one stream at one moment.
Chat is the opposite case: far too much to code, which is true of most content analysis studies
A well-drawn sample makes the work finishable and still supports the conclusions.
Population and Sample
Population: everything your conclusions will apply to, defined by the platform, the accounts or outlets, and the time period. Example: every message in the fifty example channels that week.
Sample: the smaller set of cases you actually code. Example: thirty messages from each of those fifty channels.
Sampling Frame and the Gap
Sampling frame: the actual list of items you can draw your sample from
Examples: the posts an API returns, a search result, an archive, or a list of channels
The gap: the ways the frame differs from the population, stated in writing
Examples: deleted posts, private accounts, a rate limit, or a search term that misses synonyms
Your Sampling Plan names all three, population, frame, and gap; the gap is the one most often left out
Simple Random Sampling
Simple random sampling: every message has the same chance of being picked, like drawing names from a hat. Example: R picks 1,000 messages from the whole chat table at random.
Unbiased: the way you pick favors no message over any other. Example: a message from a quiet channel has the same chance as one from a giant channel.
Its strength is real: the researcher cannot tilt the draw
Chat Volume Is Right-Skewed
Chat volume in the example data is severely right-skewed
The busiest channel logged over a million messages that week
The median channel (the middle one by size) logged about 1,440, and the quietest logged one
Right-skewed: most values are small and a few are huge, so a chart of them has a long tail to the right. Example: a few giant channels and a long, thin tail of small ones.
Unbiased Is Not Representative
Forty-three of the fifty example channels are gaming channels
Draw at random and almost every message comes from giant gaming channels
Representative: a sample that gives a fair picture of every group your question is about. Example: a sample with enough Bob Ross messages to say something about non-gaming chat.
A random draw here is unbiased and still unrepresentative of non-gaming chat
Stratified Sampling
Stratified sampling: split the population into groups, called strata (one group is a stratum), then draw from each group separately. Example: draw thirty messages from each of the fifty channels.
Every stratum gets a place in the sample, in the proportion you decide
The strata must matter for the research question
In the example study the stratifying variable is the channel
Stratifying by Channel
Whether a channel is a gaming channel is a property of the channel
So stratifying by channel puts every non-gaming channel in the sample by construction
For your own source, the stratum is whatever group your question compares: an account, a subreddit, a month, an outlet
The Example Corpus Is a Stratified Design
Its fifty channels were not the fifty busiest
Eight were fixed anchors: channels picked on purpose for variety
Bob Ross was among them, the deliberate non-gaming case
The other 42 came from ten volume bands, groups of channels with similar amounts of chat
Seed: a number that fixes a random draw so it comes out the same every time. Example: set.seed(409) gives you the same 1,350 messages on every run.
A random draw differs every time you run it
The seed fixes the starting point of R’s random number generator, so set.seed() must run right before the draw
Without a seed your sample cannot be reproduced
Nobody can check your results, including you
The Seed Itself Is Arbitrary
The number itself is arbitrary: 409 means nothing
What matters is that a seed is set and recorded, so the draw is frozen
What Power Means
Statistical power: the chance your study detects an effect that is really there. Example: with only 80 messages, a real but small gap between gaming and non-gaming chat could easily go unseen.
Effect size: how big a difference or a relationship is, on a scale that does not grow with the sample. Example: how many more percentage points of messages are aimed at the streamer in non-gaming streams than in gaming ones.
Underpowered: a sample too small to give the study a good chance of detecting the effect it looks for
Where Your Planned Sample Size Meets the Data
Sampling is not only about capturing variation
Your Research Proposal specified a minimum sample size, n, the number of cases you code
This is the week that number meets your dataset
If you need 128 and the data offers 10,000, stratification solves the problem
If you need 128 and the data offers 80, the study is underpowered
Then you change the design, or you justify the limitation explicitly in the plan.
Three Ways to Justify Your Sample Size
Your plan names the one you use and applies it consistently through the whole plan.
An effect size from a named earlier study, such as one you recorded in your Annotated Manuscripts
The smallest effect that would matter, with an argument for why a smaller difference would matter to no one
A limit on your resources, such as time, stated openly as a limit and paired with a sensitivity analysis
The sensitivity analysis states plainly what size of effect your sample can and cannot detect
Saying only that the study has 80 percent power does not justify the size; 80 percent is a convention (Lakens, 2022).
Setting Your Sample Size from Your Coding Time
Plan on two to four hours of coding in total
About one third building and revising the codebook, two thirds coding with the finished codebook unchanged
Time how long you take to code twenty items, and work out your rate per item
The table on the assignment page is only a planning estimate; your own timed rate replaces it
Sampling Check on the Hub converts your rate and your hours into a sample size
The Minimum Sample and the Cost of Each Variable
Code at least fifty units
If your rate allows fewer than fifty, change the unit of analysis instead of coding fewer units
Each added variable slows you down: coding ten variables per item roughly halves your rate
Lakens: Report How Informative a Study Was
“Do not try to spin a story where it looks like a study was highly informative when it was not. Instead, transparently evaluate how informative the study was given effect sizes that were of interest, and make sure that the conclusions follow from the data.”
Purposive sampling: choosing cases on purpose, because you judge them the most useful for the question, rather than at random. Example: picking the channels where viewers most often address the streamer.
Construct validity: whether a measure behaves the way theory says the idea should
Purposive sampling can improve construct validity; it does nothing for statistical power
The Pilot Test
Pilot test: a practice round, before any real coding, where you code a few items twice to see if your codebook’s rules give the same answer both times. Example: code twenty-five sampled messages on a Monday, then again on Wednesday with Monday’s codes hidden.
In this course the pilot is twenty to thirty items; about 30 is the usual rule of thumb (Lombard et al., 2002)
The question the pilot answers: applied independently, do these rules give the same codes?
What Reliability Means
Reliability: the codebook gives the same answer whoever holds it, and the same answer when you come back to it. Example: on both passes, a message that tags the streamer is coded “directed at the streamer.”
Each round of coding is a pass: pass 1 and pass 2
The pilot turns reliability into a number you can report
Independent Coding Passes
Independent: each coding pass is done without seeing, discussing, or remembering the other. Example: your first-pass codes stay in a hidden file until the second pass is finished.
This is not suspicion of the coder: the pilot measures the codebook
If you read your earlier codes, you measure your memory, not the clarity of the written rules
When you code twice yourself, the isolation is a time gap and a blind
At least 48 hours between passes, with the first codes out of sight
Independence in Your Protocol
The written rules must carry each classification on their own
Build the isolation into your protocol, and say so in the write-up
Why Raw Agreement Is Not Enough
Raw agreement: the share of items where the two passes gave the same code. Example: the two passes match on 74 of 100 items, which sounds respectable.
The founding example: two clinicians assigning categories blindly (Cohen, 1960)
At the observed rates for each category, they still agree often
That agreement reflects the number of categories, not judgment
With few categories, or one dominant category, coincidental agreement piles up fast.
Exercise: Reliability First
Hayes and Krippendorff (2007)
“Conclusions from such data can be trusted only after demonstrating their reliability.”
A pilot scores a kappa of 0.62 against a threshold of 0.70 named before coding. What would you look at in the disagreements before piloting again, and why there?
State the sentence you would put in the report about that result
Name whose trust the reliability standard protects: the reader’s, the coder’s, or the field’s, and say why
Report What Your Pilot Settled
A pilot is a small test, so its write-up says what the test covered
Which rules it tried, and which rules it confirmed
Note any question it left open, and the White Paper claim that question touches
The full coding run is where an open question gets its answer
Chance Agreement
Chance agreement: matches that happen by luck, even when nobody follows a rule. Example: two people flipping coins to sort messages into two categories agree about half the time.
Kappa and alpha both subtract it before they credit the codebook
Cohen’s Kappa
Cohen’s kappa: a score for how much two coding passes agree beyond what luck alone would give. Example: the example pilot scores 0.236, so most of its agreement was luck.
Kappa is built for two sets of codes and nominal categories (names with no order) (Cohen, 1960)
Two coders, or one coder twice: the arithmetic is the same
Kappa is observed agreement, minus chance agreement, divided by the room left above chance
kappa = (observed - expected) / (1 - expected)
Kappa From Zero to One
Agreement no better than chance: kappa is zero, whatever the raw rate
Perfect agreement: kappa is one
Nominal: categories that are only names, with no order. Example: “directed at the streamer” is not more or less than “broadcast to the room.”
The codebook is credited only for the agreement that luck did not produce.
Krippendorff’s Alpha
Krippendorff’s alpha: a reliability score like kappa that also works with more than two coders, ranked or numeric codes, and missing codes. Example: three coders rating how heated a message is from 1 to 5.