Entering edit mode
5.1 years ago
igperez
▴
10
I am trying to use R to find the transcription factors Pdx1/NeuroD overlapping positions that are variable distances from transcription start sites. For the SELECT/WHERE query to work, you must SELECT data from two different Excel files. this is what I've attempted
promoter2 <- sqldf("SELECT pdx_neuroD6.Chr, pdx_neuroD6.neuroD.pos-1000, pdx_neuroD6.neuroD.pos+1000, promoter1.known_gene chrom, promoter1.tx_start from pdx_neuroD6 AND promoter1 WHERE Chr = known_gene chrom AND tx_start BETWEEN NeuroD.pos-1000 AND neuroD.pos+1000")
this is the error
Error in result_create(conn@ptr, statement) : near "AND": syntax error