I'm trying to create a multilevel pie chart for several files that are in the following format:
117.txt
compartment percent sequence
dna 90 AAGTGT
dna 3 AAGTGG
dna 0 AAAAAA
...
rna 75 AAGTGT
rna 10 AAAAAA
rna 10 AAGTGG
...
...
plasma 75 AAGTGT
plasma 10 AAGTGG
plasma 0 AAAAAA
I'm trying to create concentric pie charts as a figure by ggplot with a unique color for every distinct sequence based on each file like the simplified one above (which I can read in as a dataframe df). For every compartment, there are 2951 unique sequences that are present and have a percent indicated or are indicated with a "0" if not. Therefore, every file has 2951 seqs *3 compartments = 8853 lines.
So far the code I have works well for individual files, the order of sequences doesn't necessarily follow the order of my custom palette nor are the colors consistent across each file (i.e. such that the "AAGTGT" sequence always is the same color across different input files). @Prem helped me a bit with a similar question but I can't figure out what's going on here. The code is below:
library(ggplot2)
library(randomcoloR)
pal<-c(randomColor(count=2951))
ggplot(df, aes( x=compartment, y=percent, fill=sequence) ) + labs(title="117")
+ geom_bar(stat = "identity") + scale_fill_manual(values=pal)
+ scale_x_discrete(limits=c("dna", "rna", "plasma"), labels=c("plasma"="Plasma\nvRNA", "rna"="RNA","dna"="DNA"))
+ theme_bw() + theme(legend.position="none") + coord_polar(theta="y")
+ theme(axis.line = element_blank(), panel.grid.major.x = element_blank(), panel.grid.major.y = element_blank(),
panel.grid.minor = element_blank(), panel.border = element_blank(), panel.background = element_blank())
+ theme(axis.text=element_blank(), axis.title = element_blank(), axis.ticks = element_blank())
+ theme(plot.title = element_text(colour="black", face="bold", size=24, hjust=0.5))
When I run it on my larger data file with my 2951 sequences for each of the three compartments, not only do my palette colors not necessarily follow the order of the sequences, but they are not consistent across graphs (see attached figure for data sets #117 and #129 whose majority sequences should be the same color). 
Any help would be extremely appreciated as I think this representation is truly helpful for the message of my data. Thanks everyone!
seqcolumn in your data actually besequence? The plot code usessequencefor the fill column. - eipi10