How to create a time series plot in the style of a horizontal stacked bar plot in r -
i create horizontal ‘stacked bar’ type plot in date runs along x-axis , samples appear bars on y-axis. in simple example below, have 3 samples (a, b, c) each containing 3 values (0, 1, 2). horizontal bar coloured based on value @ each time step along x-axis, end 3 horizontal bars (one each sample) run first last time point , contain series of blocks colours relate different values. for example, want value 0 blue, value 1 yellow , value 2 red: sample a, first 2 days of trace blue, next 2 days yellow, followed single blue , on…… example data: df <- structure(list(date = c("30/04/2011", "01/05/2011", "02/05/2011", "03/05/2011", "04/05/2011", "05/05/2011", "06/05/2011", "07/05/2011", "08/05/2011", "09/05/2011", "10/05/2011", "11/05/2011", "12/05/2011", "13/05/2011", "14/05/2011", "15/05/2011", "16/05/2011", &q