Right Now

subscribe to posts here                        

Recent Entries

  • mid-lab-talk summary

    I plowed through a bunch of dizzying diagrams, then repeated the exercise with these words:

    APC surface

    two dimensional hacks

    three views it gives

    three views it lacks

    A dimension of time

    of life and of death

    with cohorts defined

    by their very last breath

    topsy turvy

    realigned in a mirror

    in TPD time

    death grows nearer

    but to see variation

    within spans of life

    we need to cut time

    with a different knife

    you can squeeze out time

    or slice right through it

    the ATL plane

    is a good way to view it

    tic tocs up

    toc ticks down

    add’m together

    and lifespans abound

    a series of planes

    all stacked in a row

    gives six temporal views

    of stocks or of flows

    and as models go

    there are more and less clever

    we just need to see

    these perspectives together

    really it’s easier

    than origami

    just triangle slices

    cut like salami

    get six dimensions

    for the price of three

    it’s an aesthetic result

    between you and me

    this is not a tale

    of statistical inference

    ask and I’ll give you

    complete indifference

    but can it do tricks?

    can we make any money?

    -it tells party jokes

    but you won’t find them funny

    turns out there’s a hoax

    a crime to expose

    a detective adventure

    that I can’t solve with prose

    And then moved on to CSI Rostock: "The case of the mis-specified morbidity pattern"

    Next stop, Prague!

    Posted Jul 21, 2015, 5:58 AM by Tim Riffe
  • 6 dimensions of demographic time #demography
    This post will be woefully short. Basically, you know how with APC you buy two and get the third for free? That is, you really only have two pieces of info with APC: well, if you had three pieces of info you get SIX indices! The six indices are chronological age (A), period (P), birth cohort (C), thanatological age (T), death cohort (D), and lifespan (L). In short, you only need 3 pieces of information to build out a 3-d temporal space. For example, with 1) birth cohort, 2) lifespan, and 3) a position in time (period), then we get chrono age, death cohort and thano age for free! Who doesn't like free things?! This is an ongoing project of mine to build out a 3-d Lexis-like space. The projection you see in this WebGL object follows the right-angles that are all around in demography, whereas an isotropic (time proportions are same in all directions) version of the same space ends up being a tetrahedral-octahedral honeycomb (say what?!). This beast of a diagram was done using the rgl package in R, which lets you save to WebGL, which lets me save the thing so you can see it in a browser. But if you come hang out then we can make one out of Zometool

    This is a still-shot. Just click the image to go to the interactive (twirly) one, or visit: http://demog.berkeley.edu/~triffe/RGL1/

    I'm excited to present this (and a proper buildup to it) at a lab talk next week for the Population and Health Lab at the MPIDR. I'm also excited to present it at the upcoming EAPS "Changing patterns of mortality and morbidity : age-, time-, cause- and cohort-perspectives" workshop in Prague. By then, Jonas Schöley will have been working on an interactive Shiny App to view data that permit the use of such coordinates, and Pancho Villavicencio will be helping my dot the i's and cross the t's when it comes to describing the geometry of all this. Can you say "let's calculate some new kinds of rates!"? Demography rules.

    Posted Jul 19, 2015, 11:12 AM by Tim Riffe
  • silliness with rates
    I'm in Rostock now, been lucky with the sun so far here. I've moved a lot. It takes a while to get my work environment set up on a new machine. But git makes it easier, since the vast majority of my stuff is there, so all I have to do is clone and reproduce, and I can get started working on it. Except sometimes it's not so slick because I failed to commit the data, usually because it'd either break a user agreement, or as a courtesy to whoever gave me the data. Then it takes some shuffling to find the data, and reproduce the project. And this new machine is Windows, which is forcing me to make my R code more robust, but using the file.path() function instead of just specifying file paths with strings (path separators are different in Windows and Linux). Ugh. Anyway, the other thing about Rostock in the summer is that the night lasts like 4 hours. When you're jet lagged it's easy to stay that way. And so now instead of forcing myself to go back to sleep I started jotting down odd ideas.

    Rewind back to PAA. Virginia and VCR gave a presentation in the same session as I, entitled 'Am I Halfway There? Life-lived = Expected Life', where they looked at a couple different ways of deciding whether you're half way through life using ye olde lifetable. It sounded to me like different approaches to the old school idea of the half-life (please donate to Wikipedia!), which I mentioned in the discussion, and VCR was like 'so you mean the median?' - yup, but then I didn't know where to go from there.

    I'm going to play with that idea now and produce silliness.

    Take a lifetable's haldlife as its median, then assume that the rate that produced this half-life was actually constant (ergo exponential decay). One can calculate this rate for a lifetable that starts at age 0, or one that has been truncated at any age, or in this case all ages. Here's a pattern of m(x) [USA males, 1980, HMD]

    If we take the implied constant hazard from the remaining half-life of the survivors in each age, then plot it atop the observed rates, it looks like this:

    or it is also just its own silly rate schedule:

    [note to self: the blue line here looks eerily like the 'GHOST RATE', but I haven't checked if they're the same] Just go with it. Let it sound mysterious.

    Back to that second figure, I think the profile of the constant hazards looks like a sail. Here it is again, all saily:

    and here are the US males, sailing through time (1933-2010, really fast):
    (looks like you need to click on it, at least in my browser)

    That is, the US men's lifetable sailing team. Not very fast is my conclusion. Doldrums in the 1960s. Faster sailing in recent years.

    (created with the animation package, then sped up using the gif speed changer at ezgif.com, because it doesn't look like you can change the frame interval for gifs in R at the moment.)

    maybe I'll sleep now, thinking of sailing?

    R code here

    Posted Jul 4, 2015, 4:30 AM by Tim Riffe
  • Links to my two posters #PAA2015
    This one was a session winner. That's a project I code-name ThanoEmpirical -- Because folks seemed skeptical that the formal demography would prove useful. Well, it is. We have a sort of Ascombe's Quartet situation (HT Nikola Sander for that) that applies to how we measure various late-life morbidity characteristics. Everything can have a clear chronological age pattern in the margin, but if you break things down by thanatological age (time to death) as well, we see FOUR major patterns emerge. Take-home message #1: characteristics should be more carefully measured and considered. #2) For many conditions do not fret about the forthcoming boomer-bubble. There is a paper for that poster on the PAA website under the name Pil H. Chung, currently under review. A bit depressed that it will likely take a year to review, as we want to get the material out there.

    This one proposed four new columns for the lifetable-- Code name DistributionTTD. I think they might be useful columns for individuals planning their future (err, the data wonks out there that do fancy things to plan their own futures). Some of these columns are conditional central moments. They appear to have behaved in regular and predicatable ways over the past 40 years, and I wondered aloud if that might be worth banking on for prediction. Adam Lenart (coauthor) had a poster right next to ours where he showed how to combine moments to get back the deaths distribution. Very useful prop! People bought my speculations about applications, but I didn't get much suggestive feedback.

    These two posters share aesthetics, and were almost self-guiding, which helped a lot. Sometimes like 8 people are there and you can only talk to 1 or 2 at once. Judicious use of white space seems to keep people oriented. A very rewarding experience all around.

    Thanks all who came and chatted us up!

    Posted May 1, 2015, 8:52 AM by Tim Riffe
  • Talleres de verano #Colmex #CEDUA link: http://goo.gl/Jp2NKs
    Every summer since 2009 the Center for demographic, urban, and environmental studies (CEDUA) at the Colegio de Mexico (Colmex) puts on an awesome series of thematic one-week demography workshops: the Talleres de Verano. Great stuff. From June 15-19 I'll give a workshop doing a mix of formal demography and R visualization (of the formal demography)-- basically every odd lifetable/renewal idea that I'm currently playing with, whether published or not. Here's my proposed syllabus in Spanish (because the workshop is in Spanish, ya'lls):

    Lunes: 1. Nuevas columnas para la tabla de vida. 2. Relaciones entre la tabla de vida y poblaciones estacionarias.
    Martes: 1. ¿Cuánta vida pierde la población tras la mortalidad? Edades, causas, y relaciones entre la mortalidad y la estructura de población. 2. ¿Una tabla de vida de mejores prácticas?
    Miercoles: 1. Dos perspectivas sobre la renovación de población. 2. Demostrando la ergodicidad y el momento.
    Jueves: 1. Más allá que Lexis: Relaciones entre años vividos, años restantes, duración de vida, periodo, y cohorte(s). Diagramas, modelos, intuición. 2. Datos y simulaciones.
    Viernes: Dudas, peticiones, ejemplos, trucos y ¡diversión!

    and in English:

    Monday: 1) some new columns for the lifetable. 2) Relationships between the lifetable and stationary populations.
    Tuesday: 1) How much life does a population lose via death? Ages, causes, and relationships between mortality and population structure. 2) A best practices lifetable?
    Wednesday: 1) Two perspectives on population renewal. 2) Demonstrate ergodicity and momentum.
    Thursday: Beyond Lexis: Relationships between years lived, years left, lifespan, period, and cohort(s). Diagrams, models, intuition. 2) Data and simulations (of the former)
    Friday: Questions, comments, requests, examples, tricks and fun!

    This is going to be super fun! Plus I'll meet lots of new people! Plus I've never been to Mexico City! Thanks to Victor Garcia for the initiative and invitation! I'll report back when materials are posted, on github probably. Oh boy oh boy oh boy, a chance to corrupt share new ideas with demographers!

    *Shout out to my old adviser, Albert Esteve, who I also see on the program later in the summer. Looks like he's going to rock the iPUMS International. Remember kids, use it for good, never for evil!
    Posted Apr 14, 2015, 10:32 AM by Tim Riffe
Showing posts 1 - 5 of 127. View more »

The inelegant old-school 1-page blog has now migrated to the 'blog' tab on the left. This page only shows the 5 most recent entries.