I'm trying to ignore some 0 on a plot but I'm not finding a way to do it. i tried to use filter and which but I obtain the error "Aesthetics must be either length 1 or the same as the data (1980): y"enter image description here
above there is the code I'm using.
ggplot(data=PRICE_MSCI_MODEL_10_PAESI,aes(x=t,y=fitted_values99,group = 1))+
- geom_line(color = "steelblue")+
- geom_point(aes(x=t,y=which(D99!=0),colour="red"))+
- facet_wrap(~id) Errore: Aesthetics must be either length 1 or the same as the data (1980): y