Question: TCGA retrieving file id from submitter_aliquot_ids using the files endpoint
gravatar for sahar850
5 months ago by
sahar8500 wrote:

Hi, i got a list of submitter_aliquot_ids and i am trying to retrieve there file id.

so far i manege to get some result using R code with cURL in the cases endpoint.

the data i get is too maccey to use.

does anyone know how to get this information with the files endpoint?

the code i am using to create the query file (in R):

aliquot_list = read.csv(file ='file_name.csv', = TRUE)
id= toString(sprintf('"%s"',aliquot_list$submitter_aliquot_ids[1:62])) 
Part1= '{"filters":{"op":"in","content":{"field":"submitter_aliquot_ids","value":[ '
Part2= '] }},"format":"TSV", "fields":"case_id,files.file_id,cases.files.file_name,submitter_aliquot_ids","size":'
Part3= paste(shQuote(2000),"}",sep="")
Sentence= paste(Part1,id,Part2,Part3, collapse=" ")

the query (with cURL in the cmd):

curl --request POST --header "Content-Type: application/json" --data @Payload_metadata.txt "" > File_metadata.txt

basically i don't know what the "fields" value should be while using the files endpoint (

i tried the following: files.submitter_id, files.cases.aliquot_ids,files.cases.submitter_id,files.cases.submitter_aliquot_ids. non of them worked.

tcga R • 201 views
ADD COMMENTlink modified 5 months ago • written 5 months ago by sahar8500
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1622 users visited in the last hour