CBIIT / R-cometsAnalytics

R package development for COMETS Analytics
12 stars 10 forks source link

COMETS 1.3. SuperBatch::Table 1 functionality #26

Closed steven-moore closed 6 years ago

steven-moore commented 6 years ago

COMETS manuscripts will need descriptive data from each of the participating studies that we can show in our Table 1. The descriptive data should be output as a zip file table. For categorical variables, the percent in each category will likely suffice. For continuous variables, I suggest outputting the mean, the standard deviation, and the values at the 0th (minimum), 5th, 10th, 25th, 50th, 75th, 90th, 95th, and 100th (maximum) percentiles.

ellatemprosa commented 6 years ago

this can be done in superbatch using psych::describe(exmetabdata$allSubjectMetaData,quant=c(.1,0.05,.25,.5,.75,.90,0.95) ) for numeric vars

steve do we need to do output metabolite descriptive stat

steven-moore commented 6 years ago

No, I do not think we need the metabolite descriptive data. I've never been asked to report this and I tend to use the metabolite*metabolite correlations (which we are already collecting) for basic descriptive purposes. In theory, it would be interesting, but it's low priority so I wouldn't include it.

ellatemprosa commented 6 years ago

@steven-moore how does this excel output look, let me know if you need other summary measures before i commit. summdata.xlsx

steven-moore commented 6 years ago

Looks great--go ahead and commit

wobenshain commented 6 years ago

Are we looking to include this file in the zip? If so can you give me a sample code snippet to run this and create the file/get the filename?

steven-moore commented 6 years ago

Ella, has this code been passed on to Wesley? The version I'm testing does not include the Table 1 details.

wobenshain commented 6 years ago

I'm still waiting on this.

ellatemprosa commented 6 years ago

committed to branch ella_022118hmdbdescrip sample code csvfile<-"C:/Users/bsc-default/Documents/Comets/Testing files/DPP cometsInput_age_4_18_2017.xlsx" exmetabdata <- COMETS::readCOMETSinput(csvfile) descdata <-runDescrip(exmetabdata) OutputXLSResults(filename="descr",datal=descdata,cohort="DPP")

@wobenshain the code snippet is above

steven-moore commented 6 years ago

Table 1 is now working--both for continuous and categorical variables. Issue is closed.