ggplot(int_times,aes(x=-stim ,y=num,colour=gene)) +
scale_y_continuous(breaks=int_times$num,labels=int_times$gene) +
geom_segment(aes(xend=stim,ystart=num,yend=num),size=5) +
xlab('IW (min)') +
ylab('Genes') +
opts(title='multi')
int_times:
gene lag stim num
Pcsk1 46.53 173.53 1
serpin2 83.00 208.02 2
Bdnf 33.00 277.02 3
Fosl2 49.00 266.03 4
Pax1 33.59 243.56 5
Acan 188.49 70.30 6
Pthlh 50.00 271.45 7
Crh 35.00 359.06 8
これは私が今持っているものです
ただし、y値'stim'は、すべて0から開始するのではなく、対応する'lag'から開始する必要があります。
geom_segmentのaes()でxstart = lagを実行できると思いましたが、それはうまくいきません。
何か助けはありますか?