Description Usage Arguments Examples
Fetch biomart data set
1 |
bmt |
character: "ENSEMBL_MART_ENSEMBL", "ENSEMBL_MART_MOUSE", "ENSEMBL_MART_SNP", "ENSEMBL_MART_FUNCGEN", "plants_mart", "plants_variations", "fungi_mart", "fungi_variations", "protists_mart", "protists_variations", "metazoa_mart", "metazoa_variations" |
host_name |
character: set host name from "www.ensembl.org", "plants.ensembl.org", "bacteria.ensembl.org", "fungi.ensembl.org","protists.ensembl.org", "metazoa.ensembl.org". search host names from http://ensemblgenomes.org/info/data_access. If you can not connect, select the mirror. "asia.ensembl.org". |
dset |
character: |
attr |
character: The default values are "chromosome_name","start_position", "end_position", "external_gene_name", "description", and "strand" |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | ## Not run:
## examples ##
# return of lists of mart
res1 <- rskoseq::fetch_bmt(host_name = "plants.ensembl.org", bmt=NULL)
# return of data sets of selected mart
res2 <- fetch_bmt(bmt ="plants_mart", host_name = "plants.ensembl.org" )
# return of biomart with data set
res3 <- fetch_bmt(bmt ="plants_mart", host_name = "plants.ensembl.org", "athaliana_eg_gene")
head(res3$dat)
# select attibutes
attr_al <- biomaRt::listAttributes(res3$mart)
atr_1 <- c("chromosome_name","ensembl_transcript_id", "ensembl_gene_id",
"ensembl_peptide_id", "external_gene_name", "entrezgene", "description")
atr_2 <- c("chromosome_name","start_position", "end_position",
"external_gene_name", "description", "strand")
res4 <- fetch_bmt("plants_mart", "plants.ensembl.org", "athaliana_eg_gene", attr=atr_1)
res5 <- fetch_bmt("plants_mart", "plants.ensembl.org", "athaliana_eg_gene", attr=atr_2)
head(res4$dat)
head(res5$dat)
# If list of datasets was already created
mart_dat <- rskodat::mart_dat
mart_dat[grep("Triticum", mart_dat$description),]
args <- unlist(mart_dat[197, 1:3])
res6 <- rskoseq::fetch_bmt(args[1], args[2], args[3], attr = atr_1)
head(res6$dat)
# getSequence This function only works when used with the ENSEMBL_MART_ENSEMBL BioMart.
res6 <- fetch_bmt("ENSEMBL_MART_ENSEMBL", "www.ensembl.org", "hsapiens_gene_ensembl" )
enst <- c("ENST00000622253", "ENST00000610645", "ENST00000620820")
res7 <- biomaRt::getSequence(id=enst, type="ensembl_transcript_id", seqType="cdna",
mart=res6$mart)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.