IALSA / longitudinal-response-pattern

0 stars 0 forks source link

2016-06-30 #3

Open knighttime opened 8 years ago

knighttime commented 8 years ago

@andkov, @knighttime

Thursday June 30th, 10 am

Meeting Agenda:

  1. make sure each column represents a wave
  2. compile an R script that would prepare the raw data into the form that could be passed to the longitudinal-response-pattern function. (0-ellis-island & 1-subsetting)
  3. simplify the patterns in the table
  4. code to count the transitions from no stroke to stroke 
andkov commented 8 years ago

To do:

knighttime commented 8 years ago

This session we:

  1. compile an R script that would prepare the raw data into the form that could be passed to the longitudinal-response-pattern function from raw files sent from RADC. (ds_raw.rds & transition-count.R)
  2. Created an example file for long to wide examples. (long-to-wide-demos.R)

Next session: continue to recode the count of transitions from no stroke to stroke

andkov commented 8 years ago

Something unsettling is happing in data. Some individuals have multiple entries per wave:

ds_long %>% dplyr::filter(id == 521316)
      id fu_year stroke_cum
1 521316       0          1
2 521316       0          1

This needs to be investigated on the level of MAP curator.

NOTE for the future: insist on using the data from the curators, otherwise chaos ensues.

andkov commented 8 years ago
  • Is each data point a possible wave that exists in the study (i.e., a very small # of people (around 9) have a lot of waves, but the rest have a much smaller number…. Or, actually, those 9 just seem to have waves that are spread over a much longer period of time, though may not actually have more waves of data…?)? In other words, does each column represent a generalized wave or the waves at which each particular participant was actually enrolled in the study?

Yes. Each column represents a consecutive wave. A dot represents missingness on the measurement of interest (in this case, stroke).

knighttime commented 8 years ago

@andkov

The problem you are having with the duplicates is an issue with incorrectly merged data. My fault - I solved the problem on my end but did not upload the new ellis_island script to github.

added new file: https://github.com/IALSA/longitudinal-response-pattern/blob/master/manipulation/0-ellis-island.R

the package you need for reshape() to work is probably library(reshape2) : you should now be able to replicate my script on your computer. let me know if that wasn't it. If it's not reshape2 or stats it will take some digging.