Part of the series of comics on dating and/or math.

# dating and math

# Too Risky

Part of a series of comics on dating and math.

# Dater’s Index

Emily McDowell at mcsweenys.net chronicled her experience with online dating with her Dater’s Index. Here’s a selection:

- Number of first dates I went on from the Internet between January 2009 and November 2010:
**40** - Percentage change over the previous decade:
**+3,900** - Estimated percentage of profiles containing the description “fun-loving”:
**80** - Estimated percentage of people who do not actually love fun:
**0** - Estimated percentage of single people in Los Angeles who both work and play hard:
**85** - Number of first dates resulting in trips to the E.R.:
**1** - Estimated number of times I swore off online dating:
**5** - Number of first dates it took before meeting the right one:
**39** - Number of times we flaked out on each other before we actually met:
**3** - Time, in months, that we have now been happily living together:
**9** - Likelihood, in percent, that I will tell you online dating is the best thing ever:
**100**

Find the full version here.

# Studies show

Part of the series of comics on dating and math.

# The search for happiness

Part of the series of comics on dating and math.

I admit, it’s a stretch to call this one ‘math-related’, but math people like making lists, right? Plus, it’s xkcd.

# The Odd Couple

Part of the series of comics on dating and math.

# The Decline

Part of the regular series of comics on dating and math.

# Crying

Robin Weis, the same girl who brought us 8 years of dating data, tracked her crying patterns for *589 days, *rating them on a scale from ‘a tear or two’ to ‘I am a crumpled pile of flesh’. She cried on 216 of those days. And I thought *I *cried a lot.

** Number of Cries Per Day**

She categorized each cry into 8 general categories, shown in the graph below. The mound of purple life-related cries on the left side was largely during a 10 week trip to Europe. A large proportion of her cries were breakup and relationship related, which included finding out her boyfriend was married. Yep, that’s bound to cause some tears. Check out her full post here.

**Categories of Cries Over Time**

**What I’ve found interesting**

- Relationships and breakups appear to cause a lot of negative emotions. It’d be interesting to see what a graph of positive emotions due to relationships would look like, though that would be harder to quantify. Crying generally has an obvious beginning and end, but how would you track your start of happy feelings and end of happy feelings as precisely?

- Is travel-crying a thing? Robin mentions that almost 20% of her crying occurred while she was traveling solo. I had a similar experience recently when I was in South America. It can be particularly uncomfortable if you’re staying in a hostel and there’s nowhere private where you can just go and cry. Has anyone else experienced this?

As I’m taking my first steps into the world of online dating (I just signed up to OKCupid for the first time) it can be a little scary seeing the amount of angst relationships can cause. Might I be more comfortable staying safely single?

I hate to be yet another blog that touts the benefits of travel, but my experience with travel is relevant here. Even though I spent a lot of time being unhappy while traveling, overall it was a rewarding experience that enhanced my life and I’d do it again. As for dating, it’s a risk I’m willing to take.

# Calculate Your Dating Age Range

Inspired by this xkcd comic, I built an interactive graph and calculator. You can use it to test whether your current relationship is socially acceptable or to calculate what age is too young or too old for you to date. (It might take a few seconds to load.)

### The Equations

For the occasions when you need to quickly calculate whether pursuing a person of a particular age would be objectionable, here are the formulas:

So according to this, I could date a guy between the ages of 21 and 42. Personally, it’s wider than I’d probably date. My preferred minimum would be around 25 and maximum around 38, but for a rule of thumb, the calculations don’t seem too far off.

However, the older we get, the calculations start getting outrageous: A 51 year old can date an 88 year old? At 60 you can date anyone between the age of 37 and 106? Something seems off.

### How well do the formulas work?

Lucky for us, Psychology Today investigated this question by studying whether these formulas reflect people’s real preferences.

Here’s a summary of their findings:

- Men’s preferred minimum age for a partner is close to the formula’s minimum.
- Both sexes’ preferred maximum age is much younger than what the formula calculates.
- Women’s preferred minimum acceptable age is older than what the formula calculates.
- The younger you are, the more accurate the calculations.

You can read more here.

Now, who will create a more accurate calculation?

### The Code

For anyone interested in learning how I built this app, here’s the code. If you know R, Shiny apps are surprisingly easy to create. Check out the tutorials at shiny.rstudio.com.

# range.R# Calculate dating range and create textrange <- function(age){ max_age <- function(x) 2*x - 14 min_age <- function(x) .5*x + 7 youngest <- min_age(age) oldest <- max_age(age) paste("You can safely date someone between the ages of ", floor(youngest), " and ", floor(oldest), ".", sep = "" ) }# plot.Rage_plot <- function(){#set equations for linestop <- function(x) 2*x - 14 bottom <- function(x) .5*x + 7#set the shading colorcolor = rgb(232, 240, 237, max = 255, alpha = 225)# graph top line and titlescurve(top, xlim = c(18,100), ylim = c(18,100), xlab = "your age", ylab = "your partner's age", main = "Socially Acceptable Dating Range", col = color)# fill between linestop.x <- seq(0,110,.01) bottom.x <- seq(0,110,.01) top.y <- top(top.x) bottom.y <- bottom(bottom.x) x <- c(bottom.x, rev(top.x)) y <- c(bottom.y, rev(top.y)) polygon(x, y, col = color, border = color)# graph bottom line to add border again # (there must be a better way!)par(new=TRUE) curve(bottom, xlim = c(18,100), ylim = c(18,100), xlab = "", ylab = "", col = color)# add legendlegend(23,90, legend = "Acceptable" , cex = .9, pch = 15, bty = "n", col = color, pt.cex = 2) }# ui.R age_rangelibrary(shiny) shinyUI(fluidPage(# Sidebar with a slider input for each agesidebarLayout( sidebarPanel( br(), sliderInput("your_age", "Select your age:", min = 18, max = 100, value = 40 ), br(), sliderInput("partners_age", "Select your partner's age:", min = 18, max = 100, value = 40 ), br(),# Display the textstrong("Acceptable Dating Range:"), textOutput("text1"), br() ),# Display the Acceptable Age Range GraphmainPanel( br(), plotOutput("plot") ) ) ))# server.R Age Range Graphlibrary(shiny) source("plot.R") source("range.R") shinyServer(function(input, output) { output$plot <- renderPlot({ age_plot()# graph data point, using input from sliderspoints(input$your_age, input$partners_age, pch=20) })# Create text using input from your_age slideroutput$text1 <- renderText({ range(input$your_age) }) })