Hello dear Bioconductor support group,
I am having problems with importing this data results from featureCounts, which output has this format:
Program:featureCounts v1.6.2; Command:
featureCounts -L file.sam -g Parent -a file_exon.gff -G file.fasta -T 20 -o counts.txt
Geneid Chr Start End Strand Length M54.sam unitig_0_quiver_quiver;unitig_0_quiver_quiver;unitig_0_quiver_quiver;unitig_0_quiver_quiver;unitig_0_quiver_quiver;unitig_0_quiver_quiver;unitig_0_quiver_quiver;unitig_0_quiver_quiver;unitig_0_quiver_quiver;unitig_0_quiver_quiver;unitig_0_quiver_quiver;unitig_0_quiver_quiver;...unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver;unitig_1_quiver_quiver 568;2068334;2069275;2073626;2075076;2075787;2076821;2079662;2081007;2082574;2086372;2086736;2088493;2090226;2099578;2102000;2103077;2104046;2104689;2106631;2109282;2109929;2122067;2124736;2125261;2126211;2126765;2128874;2133886;2135222;2137655...
The problem here is that I was using the following command:
counts <- read.table("counts.txt", comment.char = "#", header=TRUE, sep = ";")
Nonetheless, with this command I cannot import my files because the first lines correspond to all row names ("unitig_*") and then, after more than 1000 lines I have the counts and the rest of the information; and I thought the featureCounts format would gave me each result in the order of appearance of every header.
Could you tell me how can I solve this problems to introduce my data results in R?
Thank you in advance.
I've reformatted your question a bit to make the code and output more readable.