Hi,

I'm trying to create an abbreviated data file from a larger version. I can
use the subset command to create a value for this data:

dat <-subset(raw.data, select=c(SNP, Pvalue))

> head (dat)
         SNP Pvalue
1 rs11 0.6516
2 rs12 0.3311
3 rs13 0.5615

but when I try to write.table using:

write.table (dat, file = "/path/to/my/data.txt", sep = " ", col.names=NA)

I end up with a file that looks like this:

"" "SNP" "Pvalue"
"1" "rs11" 0.6516
"2" "rs12" 0.3311
"3" "rs13" 0.5615

when what I want is something that looks like this:

rs11   0.6516
rs12   0.3311
rs13   0.5615

What should I be including?

Thanks,
Margaux

	[[alternative HTML version deleted]]

