perform the same command on each line of a file

Hi, I have a text file containing a list of snp rsIDs. I want to make the same request on each line of this file. The value must allow the command to be carried out on each line and therefore contain each line one after the other. Here is the code I tried:

 #> A code chunk   
Data <- readLines ("rsID.txt")

#Data_vec <- as.vector(Data) 


ensembl <- useMart("ENSEMBL_MART_SNP", dataset = "hsapiens_snp")

  "refsnp_id", "ensembl_gene_stable_id", "ensembl_transcript_stable_id"),
  filters="snp_filter", values="Data_vec",
  mart=ensembl, uniqueRows=TRUE)

but I always have this message:

[1] refsnp_id ensembl_gene_stable_id ensembl_transcript_stable_id
<0 rows> (or 0-length row.names)

How can I do ?

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.