我有一个闪亮的应用程序,我只是尝试使用group by并在renderTable中进行汇总。下面的代码在普通脚本中工作正常,但是当我尝试在闪亮的情况下运行它时,我得到以下错误。任何想法将不胜感激!谢谢。
Error in summarise_impl: Columns
4 ,
5 ,
6 ,
7 ,
8 , ... cannot have NA as
output$Risk <- renderTable({
dailyvols <- data.frame(cbind(FrontSwapLegPerf2$`Total Return`-(BackSwapLegPerf2$`Total Return`*HedgeRatios1),
FrontSwapLegPerf2$Residual))
colnames(dailyvols) <- c("Total_Return","Residual")
dailyvols$bin <- round(dailyvols$Residual)
Bins <- group_by(dailyvols, bin ) %>%
summarise(SD = sd(Total_Return))
})