Scott Alexander on the Effective Altruism Movement

Scott Alexander has a wonderful piece on the Effective Altruism Movement based on his attendance at the 2017 EA conference. Though he starts the piece with a quote from Hunter S. Thompson it reads much more like David Foster Wallace (especially this and this).

The EA movement has a surprisingly strange set of research agendas that are best summed up in Scott’s comment about the salad he ate for lunch, “Born too late to eat meat guilt-free, born too early to get the technology that hacks directly into my brain and adds artificial positive valence to unpleasant experiences.”

I was also happy to see there was an organization responding to the arguments in this Journal of Practical Ethics article, “Consistent Vegetarianism and the Suffering of Wild Animals.”

WASR [Wild Animal Suffering Research] researches ways we can alleviate wild animal suffering, from euthanizing elderly elephants (probably not high-impact) to using more humane insecticides (recommended as an ‘interim solution’) to neutralizing predator species in order to relieve the suffering of prey (still has some thorny issues that need to be resolved).

Cute Little Solution

I’m learning Ruby and one small exercise was meant to calculate the sum for simple sentences like this: “eight plus 5 plus five minus three plus 1 minus 4” and output an answer. Numbers can be either numeric or written out. Every set of numbers is separated by either “plus” or “minus.” I’m sure there are many ways to complete this problem. I came up with the cute little solution below.

NUMBERS = {
"zero"  => 0,
"one"   => 1,
"two"   => 2,
"thrid" => 3,
"four"  => 4,
"five"  => 5,
"six"   => 6,
"seven" => 7,
"eight" => 8,
"nine"  => 9
}

OPERATIONS = ['plus', 'minus']

def is_int?(int)
int.to_i.to_s == int
end

def translate_number(number)
return number.to_i if is_int?(number)
NUMBERS[number]
end

def compute(operation, number)
case operation
when 'plus' then number
when 'minus' then -number
end
end

def computer(expression)
express_array = expression.split
total = translate_number(express_array.shift)
operation = nil
express_array.each do |element|
if OPERATIONS.include?(element)
operation = element
next
end
number = translate_number(element)
total += compute(operation, number)
end
total
end

p computer("two plus two minus one plus 8 plus five minus 3")


Rape in Film

LA Weekly has an important piece this week on rape in film and TV titled, “Rape Choreography Makes Films Safer, But Still Takes a Toll on Cast and Crew.” It discusses the difficulties in filming rape scenes, abuses that have taken place in the past (especially during the 1970s), and the lack of dialogue about how much rape there should be in film and TV.

Here is one bit:

Working on Brian De Palma’s heart-wrenching war drama Casualties of War(1989), editor Bill Pankow and the postproduction crew edited one of the most emotionally charged rape scenes committed to film, in which Sean Penn’s character and three others assault a Vietnamese girl over the objections of Michael J. Fox’s character. As the editor, Pankow’s required to watch and rewatch footage, knowing it intimately, thereby getting a feel for which shots have the desired emotional appeal. After the film’s release, Pankow, in an interview that appeared in Gabriella Oldham’s First Cut: Conversations With Film Editors, revealed, “For the first few days, we couldn’t help crying just looking at the dailies.”

John Roberts’ Ninth Grade Commencement Speech

John Roberts gave a commencement speech to his son’s ninth grade class at the all-boys Cardigan Mountain boarding school.

You’ve been at a school with just boys. Most of you will be going to a school with girls. I have no advice for you.

From time to time in the years to come, I hope you will be treated unfairly, so that you will come to know the value of justice. I hope that you will suffer betrayal because that will teach you the importance of loyalty. Sorry to say, but I hope you will be lonely from time to time so that you don’t take friends for granted. I wish you bad luck, again, from time to time so that you will be conscious of the role of chance in life and understand that your success is not completely deserved and that the failure of others is not completely deserved either. And when you lose, as you will from time to time, I hope every now and then, your opponent will gloat over your failure. It is a way for you to understand the importance of sportsmanship. I hope you’ll be ignored so you know the importance of listening to others, and I hope you will have just enough pain to learn compassion. Whether I wish these things or not, they’re going to happen. And whether you benefit from them or not will depend upon your ability to see the message in your misfortunes.

Collectively, humans have watched Adam Sandler on Netflix for longer than civilization has existed

That is the title of a new Quartz piece by Ashley Rodriquez. Here is one bit:

Five hundred million hours may not sound extraordinary compared to the 1 billion hours of YouTube people watch per day. But it equates to about three movies for each Netflix subscriber—or, an astonishing 57,000 years worth of continuous viewing.

What were humans doing 57,000 years ago? Not watching Netflix, that’s for sure. It was the Stone Age and cave paintings didn’t even exist yet. The earliest known cave paintings were believed to be around 40,000 years old (paywall), although there are older known sculptures and engravings.

Distribution Convergence

Let’s do a problem from Chapter 5 of All of Statistics.

Suppose $X_1, \dots X_n \sim \text{Uniform(0,1)}$. Let $Y_n = \bar{X_n}^2$. Find the limiting distribution of $Y_n$.

Note that we have $Y_n = \bar{X_n}\bar{X_n}$

Recall from Theorem 5.5(e) that if $X_n \rightsquigarrow X$ and $Y_n \rightsquigarrow c$ then $X_n Y_n \rightsquigarrow cX$.

So the question becomes does $X_n \rightsquigarrow c$ so that we can use this theorem? The answer is yes. Recall that from Theorem 5.4(b) $X_n \overset{P}{\longrightarrow} X$ implies that $X_n \rightsquigarrow X$. So if we can show that we converge to a constant in probability we know that we converge to the constant in distribution. Let’s show that $\bar{X}_n \overset{P}{\longrightarrow} c$. That’s easy. The law of large numbers tells us that the sample average converges in probability to the expectation. In other words $\bar{X}_n \overset{P}{\longrightarrow} \mathbb{E}[X]$. Since we are told that $X_i$ is i.i.d from a Uniform(0,1) we know the expectation is $\mathbb{E}[X] = .5$.

Putting it all together we have that:

$Y_n = \bar{X_n}^2$
$Y_n = \bar{X_n}\bar{X_n}$
$Y_n \rightsquigarrow \mathbb{E}[X]\mathbb{E}[X]$ (through the argument above)
$Y_n \rightsquigarrow (.5)(.5)$
$Y_n \rightsquigarrow .25$

We can also show this by simulation in R, which produces this chart:

Indeed we also get the answer 0.25. Here is the R code used to produce the chart above:

# Load plotting libraries
library(ggplot2)
library(ggthemes)

# Create Y = g(x_n)
g = function(n) {
return(mean(runif(n))^2)
}

# Define variables
n = 1:10000
Y = sapply(n, g)

# Plot
set.seed(10)
df = data.frame(n,Y)
ggplot(df, aes(n,Y)) +
geom_line(color='#3498DB') +
theme_fivethirtyeight() +
ggtitle('Distribution Convergence of Y as n Increases')