Skip to content

Commit

Permalink
explite FLCore:::as.df
Browse files Browse the repository at this point in the history
  • Loading branch information
lauriekell committed Sep 6, 2023
1 parent 6ad91c8 commit 0a36f51
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions R/trend-plot.R
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ trendPhaseMar2=function(object,pts=object[,ac(max(dimnames(object)$year))],
panel.grid.minor = element_line(colour ="NA")
)

pbs=ddply(as.data.frame(object,drop=T),.(year), with, t(quantile(data,probs=c(0,0.05,0.25,0.50,0.75,0.95,1),na.rm=T)))
pbs=ddply(FLCore:::as.data.frame(object,drop=T),.(year), with, t(quantile(data,probs=c(0,0.05,0.25,0.50,0.75,0.95,1),na.rm=T)))

trend=
ggplot(pbs)+
Expand Down Expand Up @@ -188,7 +188,7 @@ trendPhaseMar3=function(objects,pts=FLQuants(llply(objects, function(x) x[,ac(ma

##### Density plots #############################################################################################
marginal=
ggplot(as.data.frame(pts,drop=T)) +
ggplot(FLCore:::as.data.frame(pts,drop=T)) +
geom_vline(xintercept=1,col="red")+
geom_density(aes(x = data, y = ..count.., fill=qname, col=qname),position="identity",alpha=0.5)+
#coord_cartesian(xlim=c(0,ylim)) +
Expand All @@ -212,7 +212,7 @@ trendPhaseMar3=function(objects,pts=FLQuants(llply(objects, function(x) x[,ac(ma
panel.grid.minor = element_line(colour ="NA")
)

pbs=ddply(as.data.frame(objects,drop=T),.(year,qname), with, t(quantile(data,probs=c(0,0.05,0.25,0.50,0.75,0.95,1),na.rm=T)))
pbs=ddply(FLCore:::as.data.frame(objects,drop=T),.(year,qname), with, t(quantile(data,probs=c(0,0.05,0.25,0.50,0.75,0.95,1),na.rm=T)))

trend=
ggplot(pbs)+
Expand Down

0 comments on commit 0a36f51

Please sign in to comment.