## Not run: ##acquire annotation from biomaRt
# library(biomaRt)
# anno <- getBM(
# attributes= c("ensembl_gene_id", "chromosome_name",
# "transcript_start", "transcript_end", "strand"),
# mart= useDataset("hsapiens_gene_ensembl", useMart("ensembl"))
# )
# ## End(Not run)
#define bins about the annotation
anno <- anno[order(anno$chromosome_name),]
colnames(anno) <- c("ENSG","chr","start","end","str")
ChIPannoZones <- defineBins(anno, c(-1500, 1500), geneID = "ENSG")
Run the code above in your browser using DataLab