Hi, all
I'm trying to get some snp information, such as ID, position, etc., from biomaRt. The code I'm using is attached below:
> require(biomaRt) > mart <- useMart("snp") > dataset <- useDataset("hsapiens_snp", mart=mart) > snps.chr22 <- getBM(attributes=c('refsnp_id', 'chrom_start', 'minor_allele_freq', 'ensembl_gene_stable_id', 'consequence_type_tv', 'phenotype_description'), filters='chr_name', values=22, mart=dataset)
But after hours of waiting, I always get the same error message:
Error in scan(file, what, nmax, sep, dec, quote, skip, nlines, na.strings, : line 545406 did not have 6 elements
The strange part is, if I run the above code in different terminals, I got the errors in every terminal at the same time but with different line numbers. For example, in one terminal the error message could be the one shown above while in another terminal the error message could look like this:
Error in scan(file, what, nmax, sep, dec, quote, skip, nlines, na.strings, : line 1405583 did not have 6 elements
Does anyone know why is this happening all the time? Thanks.
Sincerely,
Ting
Yes that helps! Thank you very much!
Sincerely,
Ting