Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

extract clinical data from previous research #52

Open
bioinfo-dirty-jobs opened this issue May 16, 2018 · 4 comments
Open

extract clinical data from previous research #52

bioinfo-dirty-jobs opened this issue May 16, 2018 · 4 comments

Comments

@bioinfo-dirty-jobs
Copy link

I want to download all the clinical data from the rnaseq data selected:


expands = c("diagnoses","annotations",
            "demographic","exposures")
clinResults = cases() %>%

  GenomicDataCommons::select(filter( ~ cases.project.project_id == 'TCGA-OV' &
                                       type == 'gene_expression' &
                                       analysis.workflow_type == 'HTSeq - Counts') ) %>%
  GenomicDataCommons::expand(expands) %>%
  results(size=300)
str(clinResults,list.len=10)
write.table(clinResults,"Clinical_results.csv",sep="\t",row.names = FALS
```E)
@seandavi
Copy link
Collaborator

You'll need to do this in two steps.

  1. Do your files query and include the files.cases.case_id.
  2. Use the case_ids from query 1 as input to gdc_clinical.

Give it a try and let me know if you need more direction. Great question!

@bioinfo-dirty-jobs
Copy link
Author

bioinfo-dirty-jobs commented May 17, 2018

@seandavi
Thanks so much.... I try to figure out.. .. but I miss something
Here you have what I found

q = cases() %>%
    filter(~ project.project_id=='TCGA-OV'  &
             files.analysis.workflow_type == 'HTSeq - FPKM-UQ')
q %>% count()





file_ids = q %>% facet('files.cases.case_id') %>% response_all() %>%
  ids()

So I suppose I have in file_ids How can retrive all the diagnosis data...
If I have the bcr_patient_uuid how can download the expression data?
Could you please make me some example? thanks so much for the help and patience

@seandavi
Copy link
Collaborator

I'll write something up, but it may take me a few days--sorry for the delay. I really appreciate you working through this with us.

@bioinfo-dirty-jobs
Copy link
Author

Dear @seandavi
I still try to resolve the problem... but I miss something.
So I found on cases I found this:
grep('files.cases.case_id',available_fields('cases'),value=TRUE) but not on the expand field

q = cases() %>%
  GenomicDataCommons::filter(~ project.project_id=='TCGA-OV'  &
                               files.analysis.workflow_type == 'HTSeq - FPKM-UQ') %>% 
  GenomicDataCommons::expand("diagnoses") %>% facet()
q %>% results()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants